FileMaker Pro Advanced 17 includes some useful improvements to the Show Custom Dialog script step. The Show Custom Dialog script step now allows input to be saved to local or global variables rather than only having the ability to save to a field. Let’s take a look at what changed and why you should even care.
- What Changed with FileMaker Show Custom Dialog?
- How Show Custom Dialog Feature Impacts Your Business
What Changed with FileMaker Show Custom Dialog?
FileMaker Pro 16 FileMaker Pro Advanced 17
As you can see from the screenshots above, nothing changed on the General tab of the Options dialog. You still have the ability to add a title, a message and buttons for the dialog. You can also specify a value to any of these options as well. The changes can be seen on the Input Fields tab, as shown below.
FileMaker Pro 16 FileMaker Pro Advanced 17
Once you decide to specify an input field, you will be given the new option to save user input from a custom dialog window to a variable. Other noticeable changes include a new search function to easily find fields. There’s also been a cosmetic change to make the Repetition box wider. The option to use variables makes it easier and more convenient to work with user input. In earlier versions, the only option was to store the input values into fields, which often required extra work to retrieve the values and manage the fields. This would also require you to create fields to store user input if you didn’t have them already. With variables, you no longer need to worry about any of these issues.
How Show Custom Dialog Feature Impacts Your Business
While having more options is always nice, the question is how does it really improve the application?
Fewer Script Steps
Although it might not seem like it, this will ultimately save the developer time scripting. Below are some screenshots on a report script that I created to discuss this very topic.
Input in Fields Input in Variables
As you can see from the screenshot above on the left, I would have to save the input into fields, extract the data from these fields, place them into local variables and then clear those fields so that data residing in them couldn’t be exposed later on in the application. Before version17, there was no other option so this was the only way that you could use the Show Custom Dialog script step. In FileMaker 17, I wouldn’t need to worry about writing any of these steps. The custom dialog script step now provides the option to save user input into local or global variables and then they can be used throughout the life of the script. As you can see from the right screenshot, I have saved myself from writing 4 lines of script steps. I no longer need to extract the data from fields and clear them (lines 8-9 and 17-18 on the left screenshot). You might be thinking that saving 4 lines of code doesn’t really matter but in the long run it really does. Just imagine that your database uses the show custom dialog script step quite a lot for your reports or other resources related to input in your database. If you are using the same method that is seen in my script, then you are saving yourself from writing 4 lines of code each time.
No More Schema Changes!
Before, you would need to add fields to one of your tables or use existing ones to save user input from the custom dialog window. With this new addition, you no longer need to. You don’t have to worry later on when migrating changes whether or not you need to migrate a certain field since this new addition to the script step doesn’t force you to link it back to a field. Now your databases doesn’t have to be cluttered with fields that you might only need to use once during your session of the application.
FileMaker Pro 16 had already begun expanding the idea of targeting variables to many of their script steps. The Insert From URL, Insert Calculated Result and Insert Current Time were only some of the script steps that allowed variables to be targeted. With the ability to target variables from the custom dialog window in FileMaker Pro Advanced 17, FileMaker is one more step closer in allowing all if its features to become more consistent, dynamic and separated from the schema altogether. By creating consistency, we are provided a fundamental model that allows us to use script steps in the same manner. We no longer have to use a script step and wonder why it doesn’t have the same resources as another of its similar ability. For example, the Insert From URL was able to target variables in FileMaker Pro 16. However, as previously mentioned, the Show Custom Dialog script step did not. Both script steps have similar abilities of receiving input however, they did not have the same interaction of where they could store the input they received. This was bothersome as you couldn’t enact similar actions of all script steps. The Show Custom Dialog script step has the ability to specify a value for most of its option on its programmable interface. When specifying a value, you are allowed to use a field value or even a variable value. So if we had the option to use variables for most of the output, it should be reasonable to allow variables to receive input as well. This provides total consistency in the programmable system that FileMaker contains.
With this new addition to the show custom dialog script, it will bring some changes to the programmable interface and as well to some aspects of the database and for the programmer. This might not be the most exciting feature that you might have been waiting for, however it is certainly a nice addition. This feature provides more control to our programming environment and improves the way we write code. My last question to you is, how will this improve the way you write code? Post your thoughts and feedback in the comments. Jessie Cisneros is a FileMaker 16 Certified Developer at Skeleton Key in St. Louis, MO.
About Skeleton Key
Skeleton Key helps turn complex, complicated, and outdated systems into true information platforms. Our team of consultants and developers do this by developing custom-fit software tools and reporting dashboards that help businesses find, use, and understand their data, freeing them to focus on and grow their core business. In addition to custom databases and applications, we also provide training and coaching for getting the most out of your existing systems and understanding your unruly data. Skeleton Key is an open-book management company and active player of the Great Game of Business.