Search the Community
Showing results for tags 'script parameter'.
Found 3 results
Can anyone offer an explanation for this scenario. A script on the client creates a new record in table A. Within that same script, Perform script on server is called with two parameters. Parameter 1 is the serialized id of the record just created ( the id is created upon record commit.), and parameter 2 is a global field from a different table. The Psos script goes to a layout for table B. Parameter 2 is used to find the correct record. A field in the found record is then set to parameter 1. The problem is the field set to parameter 1, has the value of parameter 1 and a carriage return. I don't know where the carriage return is coming from. Parameter 2 is fine with no carriage return. I have tried List( param1; param2) and switching to List(param2; param1) and it produces the same results. I am parsing using "MiddleValues( Get( ScriptParameter); 1; 1)" and "MiddleValues( Get( ScriptParameter); 1; 2) Since the Id field is not editable by any user, I know it is not an input error by a user. What is going on?
FileMaker 16 introduced a collection of built-in functions for manipulating data serialized as JSON. This makes it easier for FileMaker applications to interact with many web services. This will also make JSON the de facto standard format for scripts within FileMaker to pass parameters and results to each other, improving code sharing within the FileMaker community. JSON does not have a broad palette of scalar data types to choose from: text, number, boolean, and null. Even with those, FileMaker's JSONGetElement function always returns a text result, even when the serialized JSON value is a number or boolean. So I made a handful of custom functions and scripts for sending and receiving typed data with JSON. The module is hosted on GitHub, or you can download it directly.
Monarch posted a topic in Managing ScriptsI want to create an image of the clock, with round dial, numbers as buttons (from 1 to 12, maybe even half an hour numbers). So here is the challenge (for me...): 1. Each button changes color on a corresponding slice of the clock, if you click once - white, click again - original color and so on back and forth between those two colors... Multiple colors would be nice too. 2. Using two buttons to select a chunk/slice of the dial, for example click on 12 and 4 will turn slice between 12 and 4 numbers into white color automatically without clicking on each number in between. OK, changing colors - conditional formatting - easy. Using one script for doing it - script parameter - easy. But then I can't get my mind around the rest of the puzzle. Here are my questions: a. How to keep selected color (it changes if I click different number), without going into using complex calculations and multiple fields. b. For my second problem (creating a slice) - I don't even know how to approach it... c. Also simple question: what is better to use as buttons in this case - field, object, or smth else? There must be a much more efficient and elegant way to do it. My guess is - variables, but I m getting lost with them. Any help please...