« XML and JSON Colorize… | Home | Invitation à la 7e Co… »

Trace with parameter names

Our MBS Trace function will get an upgrade for the version 12.1 of MBS FileMaker Plugin: Since we now sync parameter names as metadata into our C code, we can show it in the user interface on macOS, currently planned with a tooltip on function names:



We add Plugin.GetFunctionParameters function to query it programmatically and we use it to annotate our trace logs:

09:02:16.113929+0100 MBS Plugin version 12.0.0.10 for Mac 64-bit loaded for FileMaker Pro 19.4.
09:02:35.847284+0100 Script "Run" in file "Barcode Generation".
09:02:35.847336+0100 MBS Plugin call #1 with 10 parameters.
09:02:35.847382+0100 Parameter 0 FunctionName: "Barcode.Generate"
09:02:35.847413+0100 Parameter 1 symbology: "UPCE"
09:02:35.847453+0100 Parameter 2 Text: "1123456"
09:02:35.847482+0100 Parameter 3 width: 0
09:02:35.847510+0100 Parameter 4 height: 0
09:02:35.847548+0100 Parameter 5 rotation: 0
09:02:35.847589+0100 Parameter 6 scale: 4
09:02:35.847629+0100 Parameter 7 Transparent: 0
09:02:35.847656+0100 Parameter 8 ShowText: 1
09:02:35.847681+0100 Parameter 9 Encoding: "UTF-8"
09:02:36.246356+0100 Result #1: "18001"
09:02:36.246474+0100 MBS Plugin call #2 with 1 parameters.
09:02:36.246511+0100 Parameter 0 FunctionName: "IsError"
09:02:36.246659+0100 Result #2: 0
09:02:36.246854+0100 MBS Plugin call #3 with 3 parameters.
09:02:36.246887+0100 Parameter 0 FunctionName: "GMImage.WriteToPNGContainer"
09:02:36.246915+0100 Parameter 1 ImageRef: "18001"
09:02:36.246939+0100 Parameter 2 Filename: "barcode.png"
09:02:36.259191+0100 Result #3: Binary Data with 3 streams, 2503 Bytes in total: FNAM "file:barcode.png", PNGf "‰PNG........IHDR...8...Ø.....@ْé....bKGD.ÿ.ÿ.ÿ ½§“...|IDATxÚíÝÑn›@.@ÁRõÿ\^?™¾¶‘bä°ËÂñÌkd..@G˕Ùö}ß\^?ñc", SIZE 568 x 472
09:02:36.259617+0100 MBS Plugin call #4 with 2 parameters.
09:02:36.259660+0100 Parameter 0 FunctionName: "GMImage.Destroy"
09:02:36.259690+0100 Parameter 1 ImageRef: "18001"
09:02:36.260021+0100 Result #4: "OK"

As you see the parameter names are now showing there right in the log. We hope this helps you debug the functions.
Coming soon in 12.1pr1. Claris FileMaker Plugin
24 01 22 - 09:11