Data File Calculations

Before you think the thought "Oh, I'll just add another calculation", you need to ask yourself, "Seriously, how many calculations is too many?", and while the real answer to that question is entirely subjective, there is a real consideration when it comes to solution bloat. I'm sure you've never experienced that - right?

As you likely already know (or maybe you don't), one of the biggest challenges of any growing solution is the management of its multiple facets. Too many table occurrences on the graph -- it seems messy. Too many fields in a table -- you end up asking "What does that field do now?". Too many hidden tabs on a layout -- you're scratching your head about what you did and hoping you don't mess things up.

Simply, there are times when all you need is some type of calculated value. When you finally realize this, the solution is simple. Just one convenient script may be all you need.

Watch this video for a great technique for passing calculated information between files. This works not only for a Data/Interface separation model, but also for useful FileMaker development tools - of which one is included with this video.

AttachmentSize
Solution.zip261.66 KB

Comments

Greetings,

Using FMA 11.0.1 on Mac OS 10.5.8, 2.4 GHz Intel Core 2 Duo, 2GB Memory...

I open the Developer Startup file and, after the initial 2 files are opened, FileMaker is unresponsive. I have to go to Force Quit. I'm sure it must be a security issue. Any thoughts?

Paul Fenley
K Dunn & Associates
800-553-0135 ext. 105
In-House Developer
Database Programming Since 1980

Paul Fenley
K Dunn & Associates
800-553-0135 ext. 105
In-House Developer
Database Programming Since 1980

Hello again,

This time, I followed your steps from your video and attempted to open the My Solution file, first, got the warning dialogs and the solution quit itself. Then I opened the Developer Startup and now everything works. Very clever...

Paul Fenley
K Dunn & Associates
800-553-0135 ext. 105
In-House Developer
Database Programming Since 1980

Paul Fenley
K Dunn & Associates
800-553-0135 ext. 105
In-House Developer
Database Programming Since 1980

Using the custom function, aptly named, "developer", you can work on the file WHILE it is in development mode. The Startup script on the file looks to make sure you don't leave it in this mode and if so, it will shut down the file.

To take the file out of developement mode, you need to remove the "or True" at the end of the custom function "developer" where it says


Get ( CurrentPrivilegeSetName ) = "[Full Access]" or True

The reason for doing this is that you're using the "developer" custom function to test for scripts which do development types of things, such as the script Developer Switch Accounts

The WHOLE goal here is to make it convenient to switch between accounts (again WHILE DEVELOPING) and NOT store any credentials within the actual solution which is deployed. Therefore, we use the Developer Startup file to store this stuff, keep it on our development machine and make our lives that much easier!

-- Matt Petrowsky - ISO FileMaker Magazine Editor