HOnza’s Bits @24U

What do the capital O, FileMaker, AppleScript, and iPhone have in common... 
« Back to blog

Indicate Progress in FileMaker Go and 11

When I was preparing a sample file for the How To Prevent Support Calls video I wanted to make it as cool as possible, so I decided to optimize it for FileMaker Go. I quickly discovered that I need a plug-in free alternative for the progress dialog.

 
I wanted something nice looking while still as easy to implement as 24U SimpleDialog Plug-InThat really was the kind of challenge I like. I started getting ideas only to deny each of them in the very next second:
 
  • New window displaying a special "progress bar" layout - not good for Go, problem with maintaining script's context.
  • Transparent web viewer in the front layer rendering CSS - too complicated to develop, may be hard to interact with objects behind the web viewer. I also thought that rendering HTML is a bit of overkill.
  • Collection of fields to display progress status and progress bar - the oldest approach, a little boring, and too difficult to copy across solutions.
 
Then I got this one which I implemented in the sample file: conditional formatting

 
In this implementation a single global text field displays the progress status, 10 text objects use conditional fill color to show the progress bar, 2 button objects use conditional fill color to serve as a dialog-like background and frame. To implement it into your solution you only need to copy one field, one group of layout objects and then update the progress field and refresh window from within your script. Fair enough, isn't it? Well, not for me... ;-)
 
So I asked myself - can I make it even simpler? And I got another idea: merge variable
 

Then I created the final implementation:
  • No plug-ins
  • No fields
  • No dependency on the database schema
  • A single layout objects group to copy
  • No modifications necessary
  • Driven by a single global variable: $$progress
  • Works in FileMaker Pro 11 and FileMaker Go

And here it is for you to take and use for free:

Download the FP7 file
(even directly to iPhone or iPad with FileMaker Go installed)

or download a zipped copy

How do you like it?

Comments (13)

Jul 29, 2010
Steve Wright said...
Pretty cool thanks, I was thinking of a good way to do this myself. Just dont try it on Windows :-P the refresh window step causes too much flicker.

However on that note, inside the loop if you replace the refresh window[] step with :

Pause/Resume [Duration (seconds): 0 ]
Freeze Window

it refreshes itself without flicker.

Jul 29, 2010
Paul said...
Very nice, HOnza. Unrelated question: How do you put round corners on a text box?
Jul 29, 2010
HOnza Koudelka said...
Good poinr, Steve! Thanks. Paul, you've made me correct the article - check the difference ;-)
Jul 29, 2010
John Sindelar said...
HOnza, Steve... brilliant.
Jul 29, 2010
Paul said...
ahh... perfect. Thanks HOnza!
Jul 30, 2010
HOnza Koudelka said...
John, thanks, praise from you counts twice ;-)
Jul 30, 2010
Fabrice Nordmann said...
Honza, I've learned a lot with this file and other readers' comments. Thanks a lot for sharing this!
Jul 30, 2010
HOnza Koudelka said...
Thanks, Fabrice. I'm glad it helped you. Hope you'll share when you improve it even more...
Jul 31, 2010
Beatrice Beaubien said...
Thanks HOnza, this is great!
Aug 18, 2010
Tim Cimbura said...
Great solution! Thanks for sharing it.
Aug 26, 2010
Denis Somar said...
This is a great technique. When I open the indicate progress script on v11 on OS X 10.6, I see a lot of <function> insertions. Is there a component missing? The file still demos correctly though?
Aug 26, 2010
Denis Somar said...
that last comment is supposed to say function MISSING insertions
Aug 27, 2010
HOnza Koudelka said...
Thanks for the comments. I am glad you like the solution.
To Denis: the script automatically uses 24U SimpleDialog Plug-In in FileMaker Pro when it is installed. If you don't have SimpleDialog installed it will simply automatically use the plug-in free implementation.

Leave a comment...