View and Edit Modes in FileMaker


One of the most powerful FileMaker features is also a major weakness:  the easy accessibility to edit records is both a curse and a blessing.  Most databases deliver the results of a query as a table, and the data is not usually directly modifiable. The user (and the developer, by extension) must make changes and submit them, causing an update command to run in order to make the changes.  By default with FileMaker, the data is live and easy (some say too easy) for the end user to change.  We all have stories were the first record in the database is changed all of the time by unsuspecting new users. What FileMaker has always needed is View and Edit modes.

There have been plenty of tricks developed over the years to work around this issue:  sessions, tabs, duplicate layouts with editable fields, and dashboards, to name a few.  But none of them worked as easy as one of the first databases I ever used (Omnis 5, if you must know.  And yes, I am showing my ancient roots).  Omnis 5 had a very simple set of buttons on the left of every layout:  Edit, Save, and Cancel.  By default, with no herculean programming by the developer, the data fields on a layout were not modifiable.  Click the edit button and all fields were modifiable.  Click the save button to save, or the edit button to cancel and return to non-editable mode.

I have looked for an easy solution to this since the first time I used FileMaker (a long, long time ago).  Ryan Klenk, of Anvil Dataworks, has posted what I consider to be the closet solution we’ll probably ever see to this problem.  FYI, Ryan refers calls this functionality part of a larger idea called “Dynamic Views”:

Prior to FileMaker 13 you would use tab controls to create a dynamic view, a section of a layout that changes based on some condition or action.

Ryan goes on to describe alternative ways developers have used over the years before naming Slide Controls as the new way to easily solve this problem.  First, view mode:

Data in view mode


Click  the edit button and the slider presents this view:

Edit mode layout

One layout, two modal views.  Easy to build, easy to maintain.  An added security feature could include changing the background color to red  (or some other color than view mode) to cue the user in when they are in Edit mode.  Much easier for the user, much easier for the developer.

Follow the link below to read the whole post and to download the sample file.  Great idea, Ryan!

Anvil – Blog.

Other posts that might interest you

Liked Liked
Need FileMaker Development Help? Or to purchase FileMaker Software?
Contact FM Pro Gurus for help