appstream catalog

Extending the Power of FileMaker in the Cloud with Amazon AppStream 2.0

Over the past several years, FileMaker has entered the cloud computing landscape. FileMaker Server can be run in the cloud through a cloud services provider such as Amazon Web Services (AWS) or Microsoft Azure. And in late 2016, FileMaker unveiled FileMaker Cloud, a new AWS-based service that allows you to deploy a FileMaker server without having to spend the time and resources normally required to build out and manage a server machine. The benefits of cloud computing are many. Reliability, availability, redundancy, scalability, security, and cost optimization are all reasons to consider employing cloud services for your computing infrastructure needs. The fact that you can provision a FileMaker Cloud server and not have to worry about hardware failure or replacement, disaster recovery, or managing the server OS, makes the prospect of running a local server machine much less attractive (though there might still be valid reasons to do so). Even with all these benefits, running FileMaker Server in AWS does have its drawbacks. Chief among these is performance: If you’re connecting from your office to a FileMaker database hosted in AWS, you’re doing so over the WAN. There are ways to optimize FileMaker for WAN performance, but if your database is sufficiently complicated, performance over the WAN simply might not be workable. Enter AppStream. Amazon’s AppStream 2.0 is an application streaming service that allows you to stream desktop applications from AWS to a user through a web browser. Because AppStream instances live in AWS, you can configure a fleet to run in the same AWS region as your FileMaker server, effectively putting them in the same local network and giving you the speed of a LAN connection. Moreover, since AppStream applications are delivered through a web browser, users don’t actually have to install FileMaker Pro on their local machines. You also get the benefit of elastic pricing with AWS; you only pay running instance fees when there are active user sessions. These factors make AppStream worthy of consideration for anyone hosting their FileMaker solution(s) in AWS. Skeleton Key recently had a project that involved an AppStream deployment. Since this was our first time working with the service, we thought we’d share our findings. We’ll start with an overview of the AppStream architecture and then dive into specifics on how running FileMaker Pro inside AppStream differs from the standard FileMaker experience.

How it works

AWS account

AppStream runs in AWS, so if you’re interested in setting up an AppStream environment, the first thing you’ll need is an AWS account. If you’re already running a FileMaker Cloud server, or a regular FileMaker Server in AWS, you’ll already have this set up, but if not, it’s pretty straightforward. Do bear in mind that there are costs associated with most AppStream resources, so any testing you want to do will incur some cost.

Setup

Using the AppStream image builder, you create an image that contains the application(s) you want to make available for streaming, such as FileMaker Pro. You then configure a fleet, or a set of instances running this image. Fleet options include AWS instance type (to meet your particular performance requirements), capacity (minimum and maximum number of running instances), and scaling policies (to dynamically create or reduce available instances based on user demand). Finally, you create a stack, which controls access to your fleet. Note that currently the only OS platform available in AppStream that is supported by FileMaker Pro is Windows Server 20xx. This has several implications that we’ll get into shortly.

AppStream Image Assistant

In the AppStream image builder, use the Image Assistant to select the applications you want to make available to your streaming users.

Users and access

With your base image, fleet, and stack in place, it’s time to get your users connected. Through the AppStream user pool, you add your users and assign them to your stack. Each user gets a welcome email and a link to your AppStream URL. This URL is the same for everyone in your user pool, so it’s easy to keep track of, and while the URL itself is a bit ugly, you can use a URL shortening service like Bitly to create a custom link that’s easy to remember. Note that AppStream sessions can only be run on browsers with full HTML 5 support, including Google Chrome, Mozilla Firefox, Microsoft Internet Explorer, and Microsoft Edge. It will not currently run on Safari.

User Experience

After logging into AppStream, you land on the catalog screen which displays icons for each streaming application defined for your image. You then simply click on an icon to launch the application. While working in AppStream is similar to a remote desktop experience, the remote machine is not fully exposed to you; you only have access to the applications that are configured for streaming and listed on the catalog screen. The first thing you’ll notice after opening a FileMaker database via AppStream is that you’re getting the FileMaker Pro client experience. You’re working in a web browser, but it’s not WebDirect, it’s FileMaker Pro. That’s pretty slick! You’ll also see that you’re getting the Windows flavor of FileMaker Pro. This will be a bit of a change for folks who are used to running FileMaker Pro directly on their Mac. However, with the release of FileMaker Pro 16, the Windows interface has been significantly improved and now works more like the Mac OS version, so this is less of an issue than it might have been for earlier versions. While AppStream gives you the FileMaker Pro experience, there are several peculiarities to the AppStream interface that make it its own animal.

Home Folders

During an AppStream session, FileMaker can only access data that is local to the Windows instance you’re connected to. This means that, for example, anytime you want to insert or download a container file, or import from or export to an Excel file, you need to take additional steps to move the associated file between your local machine and AppStream (or vice versa). This is done using the Home Folders feature, which is an extension of Amazon S3 bucket storage. A user’s Home Folder behaves like a normal Windows folder, but it is specific to the user and cannot be accessed by other users. To move files between your machine and AppStream, use the My Files menu from the web view session toolbar. From there, you can upload to or download from your Home Folder. To access your Home Folder within FileMaker Pro, it appears as a folder under This PC in the file browser. One oddity with the Home Folders feature is that while you can save and rename files in your Home Folder, there isn’t currently a way to delete a file within AppStream. The only way this can be done at present is through the Amazon S3 dashboard in the AWS Console, which is probably not something you would want to grant access to for your users. Hopefully Amazon will address this at some point.

AppStream Home Folders

An AppStream user’s Home Folder is available under the My Files menu.

Printing

Printing from FileMaker in AppStream is, for the most part, surprisingly seamless. The native print command opens the standard Windows print dialog box. Amazon’s “DCV Printer” is the default selected printer, and clicking OK will generate a PDF of the current layout in a new browser tab or window (based on your browser’s settings). From there you use your native browser’s options for printing to a local printer or downloading the PDF. Because the user will always need to choose what to do with the PDF in the new browser tab, you can save them an extra mouse click with any scripted print by turning off the user dialog in the Print script step. In our testing we found that the Amazon print driver’s minimum print margins are larger than expected, resulting in content of PDF’s getting cut off for some layouts. Your mileage may vary; be sure to test every report your users might access via AppStream and adjust the layouts as necessary. You can also use FileMaker’s Save as PDF function. This works as expected and avoids the minimum page margin issues noted above. However, it utilizes the Home Folders feature, so it requires an extra step to move a PDF all the way down to your local machine.

Clipboard

Working with the clipboard is one of the more awkward tasks with AppStream, since AppStream’s clipboard is separate from your local machine’s clipboard. If you are logged into a FileMaker database and want to copy a value from one field and paste it to another, that all happens within AppStream’s clipboard and is fairly straightforward. Just keep in mind that you are working in a Windows environment, so you need to use the Windows keyboard shortcuts (control key instead of the command key) even if you’re working on a Mac. On the other hand, say you want to copy a value from a message in your local email client and paste it into FileMaker running in an AppStream session. This requires moving the value from your local clipboard to AppStream’s clipboard. To do this, open AppStream’s clipboard menu in the web view session toolbar, and select the Paste to Remote Session option. Then use your local machine’s keyboard shortcut to paste the value to the remote AppStream session. You would finally use the Windows keyboard shortcut to paste the value into FileMaker. To copy from an AppStream session to your local machine, just reverse the sequence: Copy the value in AppStream using the Windows shortcut, open the AppStream clipboard menu and choose Copy to Local Device, use your local machine’s keyboard shortcut to copy the value to your local clipboard, and then finally paste the value as you normally would into your local application. It takes a bit of practice to make these tasks routine.

AppStream Clipboard Menu

AppStream’s clipboard menu.

Be sure to test!

One strange issue we encountered was an apparent errant record locking behavior with a simple scripted action. Our database has a layout with web viewer running a data URL (more on this below). Clicking a particular button in the web viewer runs a script via FileMaker URL that opens a new window, goes to a layout, finds a record, and modifies it. The layout in the new window is configured to run a triggered script on layout load which also sets a few fields. This process worked fine for years, but when using the database via AppStream, the Set Fields initiated by the triggered action intermittently failed with a record locking error. After a lot of testing, it turned out that the initial new window action was sometimes opening two windows, and the first window was causing the record lock. We simply attributed this to slight behavioral differences with AppStream (in our case with triggering a script from a web viewer using a FileMaker URL), and we were able to script around it. More generally, though, it’s an indication that one should plan for unexpected quirks when deploying AppStream environments for use with FileMaker, and it’s important to perform a full test of your FileMaker app within Appstream to identify and address any issues as early as possible.

AppStream Persistence Considerations

Beyond these basic differences in FileMaker’s behavior between a standard client experience and an AppStream session, there are more fundamental aspects of AppStream’s architecture that will impact your FileMaker AppStream deployment. When a user launches an AppStream session, they connect to an instance of your base image that is running as part of your fleet. This instance does not persist over time; it is dynamically created and later eliminated, all based on how you configured your fleet. As a result, any changes to the machine or to local user settings during a user’s session are lost when the user’s session ends. The only exception to this is files stored in Home Folders as described above. Below are some specific persistence-related issues to be aware of.

FileMaker Pro updates and other application patches

When FileMaker releases a new patch for FileMaker Pro, users will get a software update prompt the next time FileMaker Pro launches, and this is no different for FileMaker Pro running on AppStream. However, any software updates run on an AppStream instance are temporary, since the instance does not persist. This behavior will not be intuitive to users, so you will need to advise your users to ignore any software update prompts. The solution is to run FileMaker Pro and other software patches in the AppStream image builder instance. You then create a new image and associate your fleet with the new image.

FileMaker Pro settings

For FileMaker Pro, the lack of persistence with local user settings impacts very basic things like favorite hosts, favorite files, default account name, file cache size, and more. The most impactful of these limitations is the inability to save favorite hosts and files. If we don’t want users to have to browse for their FileMaker server and hosted files each time they want to open a database while connected to AppStream, the solution is to create a dedicated AppStream “App” for each database your users will need to access. When you create an App in the AppStream Image Assistant, you select the FileMaker Pro executable file as the application launch path, but you can also specify a custom display name and launch parameter. To customize the App for a particular database, enter an appropriate display name, and then create and specify a launcher file as the launch parameter. The launcher file is a traditional FileMaker Pro “opener” file which has a single script configured to run on open that opens the remote database and then closes itself. AppStream allows you to create multiple application instances for the same underlying application, so you can just repeat this process for each database. The only catch is that the underlying App name, in addition to the display name, needs to be unique. The name defaults to “FileMaker_Pro,” so you can simply append a different sequential number (or some other value) to the end of the name for each App definition. With your AppStream Apps created in this way, the user’s AppStream catalog screen functions in much the same way as the Favorites section of the FileMaker Pro Launch Center. The user will see icons for each of their databases, and clicking on an icon will open FileMaker Pro and run the launcher file to open the remote database.

AppStream catalog screen

AppStream catalog screen with FileMaker databases configured as individual Apps.

At present we haven’t figured out a way to configure AppStream to set and remember a user’s default account name. It may be possible to accomplish this through Local Group Policy and a Windows startup script (similar to how we handle the time zone below), but that’s a future exploration.

Time zone

By default, Windows Server 2012 and higher resets its time zone to UTC time after a restart. If you try to update the time zone in the image builder instance, it doesn’t persist into the image you create with it. When users run FileMaker in an AppStream session, FileMaker uses the AppStream instance’s time zone for time considerations such as auto-enter timestamps. If your FileMaker solution requires this information to be accurate, you’ll need to take additional steps to ensure time zone accuracy. The solution is to configure the Local Group Policy in the image builder instance to run a startup script that changes the time zone. Local Group Policy persists into the base image and hence into AppStream instances, so with this in place, as each AppStream instance is created, the time zone is set at startup.

Internet security settings

Another case where local user settings can come into play with AppStream and FileMaker is internet security. By default, Windows Server 20xx comes with Internet Explorer Enhanced Security Configuration enabled. This can cause certain websites to not display properly (or function at all), block downloads, and cause other potentially undesirable behavior. For FileMaker, this obviously comes into play when running an Open URL script step, but it also impacts use of the web viewer object. Web viewers use the operating system’s built-in web browser technology, so for Windows Server, that means Internet Explorer, and IE’s security settings are in play. Internet Explorer security settings can even interfere with data URL’s in the web viewer. For example, our particular client’s application uses the Reactor plug-in to render a calendar in a web viewer. Reactor constructs elements of the data URL using the loopback IP address (127.0.0.1), and since IE Enhanced Security Configuration blocks this, the web viewer displayed an IE security message instead of the calendar. Normally, the fix would be to simply have the user open IE and add 127.0.0.1 to their intranet zone trusted sites list, but in AppStream, such a change would not persist beyond the user’s current session. As with the time zone, this must be dealt with in the image builder. And similar to the time zone setting, simply changing Internet Explorer’s security settings directly through IE’s interface will not persist into the fleet instances running the base image. This is because IE security settings are stored at the user level. Work done in the image builder happens under the Administrator user profile, but when regular users connect to an AppStream instance, the Windows instance builds them a new user profile when they log in. This user profile is based on the Windows default user profile, so the fix is to update the IE settings for the default user profile. This involves working in the Windows Registry Editor, which is a little complicated, especially if you’re not familiar with how the Windows registry works.

Conclusion

As you can see, AppStream’s architecture introduces many complications when used to stream FileMaker database connections. Some of these are more problematic than others. In our experience, though, none of these were deal breakers, and AppStream solved the primary need for our particular project, which was LAN-level performance for a database running on FileMaker Cloud. This demonstrated to us that AppStream is a viable tool for use with FileMaker and that it should be considered for use with any FileMaker deployment in AWS where performance is a top priority. One last note: in the interest of keeping the flow of this post as smooth as possible, we left out details on many of the tasks described, such as setting the time zone through local group policy, configuring FileMaker launcher files for use with AppStream, and modifying Internet Explorer security settings in the registry. If you’d like to see any of these fleshed out in a follow-up article, please comment below!

Resources

Amazon AppStream 2.0 Homepage AppStream 2.o Developer Guide For additional information on FileMaker, AWS, and AppStream, see this excellent post from Mike Duncan at Soliant Consulting.   Stu Dietz 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.

sk alexa ask filemaker06

January-FileMaker STL Meetup: “Alexa, ask FileMaker…” recording and sample files

On January 23rd, Jeremy Upton gave a fantastic presentation to the FileMaker STL Meetup group to demonstrate how Amazon Alexa and AWS Lambda can be used to create a voice interface to a FileMaker app. Here’s the full recording of the meetup:

Demo File

Click here to download Jeremy’s sample files, including a ten minute instructional video.

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.

fmp16 adv icon

FileMaker 16 Platform

The FileMaker 16 Platform has launched and it’s packed with great new features for both developers and users. We’re excited about significant new features such as server-side PDF creation, card windows, the new Windows UI, enhanced data viewer, and native JSON functions. The platform also introduces several innovative features such as the FileMaker Data API, external script steps, OAuth 2 support, and region monitoring. The new FileMaker 16 Platform is stronger than ever and we can’t wait to start building with this great new feature set. Our team has written a series of blog posts to introduce some of our favorite new features. Check back soon for more posts. FileMaker 16: Card Window by Jay Sayers FileMaker 16: Layout Objects Window by Alan Kirtlink FileMaker 16: New Windows Interface by Calvin Cooper FileMaker 16: Data API by Todd Stark FileMaker 16: Enhanced Data Viewer by Jay Sayers FileMaker 16: Animations and Transitions by Chad Adams FileMaker 16: New JSON Functions by Jeremy Upton

Greg Lane is VP of Application Development at Skeleton Key and a FileMaker Certified Developer.

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.

FileMaker 16: Animations and Transitions

Are you using FileMaker Go to build mobile solutions? Would you like those solutions to look and feel more like other mobile apps? FileMaker 16 comes with some new layout transition animations that will make your FileMaker Go solutions look, feel and behave much more like mobile users have come to expect. Since the addition of the Set Layout Object Animation script step and slide panels you have been able to mimic a slide transition while navigating from layout to layout. The cost of implementing this simple UI experience is a complication of your layouts that may be unacceptable. FileMaker 16 vastly simplifies the process and at the same time adds many more transition options. The new transitions are:

  • Slide in from Left
  • Slide in from Right
  • Slide in from Bottom
  • Slide out to Left
  • Slide out to Right
  • Slide out to Bottom
  • Flip from Left
  • Flip from Right
  • Zoom In
  • Zoom Out
  • Cross Dissolve

Watch the video below for an example of each one of these transitions.

Keep reading as we explore some of the following questions:

  1. Do do these new animations rely on or ignore the “Set Layout Object Animation” script step?
  2. What is the difference between transitions that appear to be opposites? (i.e. Slide out to Left vs Slide in from Right)
  3. Can I control the speed of the animation?

Do do these new animations rely on or ignore the “Set Layout Object Animation” script step?

In my testing the Set Layout Object Animation script step has no impact on the new layout animation features. This is a good thing. The layout animation is not tied to any specific “Object” on the layout and it would just cause confusion if there were some correlation between that script step and this new feature.

What is the difference between transitions that appear to be opposites? (i.e. Slide out to Left vs Slide in from Right)

The difference between all of the “out to” and “in from” transitions is where the animation starts from. I’ll try to demo this in the video. When using any of the “out to” animations the layout you are looking at appears to slide away (in the direction you have specified) with the new layout being revealed as if it were under the layout you are leaving. When using any of the “in to” animations the layout you are looking at appears to get covered up by a new layout sliding into the viewing area. The current layout has an appearance of going to the background as the new layout slides in to cover it up with the new layout now appearing “on top of” the layout being replaced.

Can I control the speed of the animation?

The short answer…No, not really. There are not any speed controls within the Go To Layout script step. I experimented with making layouts wider (thinking there would be more to slide out and thus it would take longer), but that did not seem to change the speed or time of the animation. The “screen” is used for the animation, not the entirety of the layout, even if some layout objects are off the current viewable area of the screen.

Summary

We have some new tools to make our solutions even better and our customers happier. Play with these animated transitions and find the ones that work best for your solution. A small word of design advice. New animations are fun and can be addictive, but too much might make your users “sea sick”. My advice is to pick a transition or two for your solution and stick with that through the whole solution. Otherwise your solution may look as bad as a dated web page from the 90’s with dancing animated gifs 🙂 Chad Adams is a FileMaker 15 Certified Developer at Skeleton Key. 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.

FM16 Windows New Windows

FileMaker 16: New Windows Interface

With the release of FileMaker Pro 16 a great new feature has been introduced for those of us who use the Windows operating system. The FileMaker Pro 16 Windows interface has been redesigned to work more like the Mac OS version by now allowing multiple and separate windows! No longer will Windows users be limited to keeping all their layout windows within the FileMaker Pro application window.

Separate Windows

Individual windows can now be resized independently. Each window also contains its own menu bar and status toolbar. FM16 Windows - New Windows

Window Snapping

Windows natively has a window snapping feature when dragging windows to the sides of the screen. You can now effectively leverage this snapping feature with the changes to the FileMaker Pro 16 Windows interface. FM16 Windows - Window Snapping

Improved Scrolling

Another perk of the FileMaker Pro 16 Windows interface is that mouse scrolling no longer scrolls records and instead vertically scrolls the layout! This is a much-requested feature that I hear from many clients. You no longer must rely on “workarounds” to keep the user from navigating away from their current record due to an awry flick of the scroll wheel.

And One Minor Inconvenience

Finally, there is one change that I have come across so far that may cause some frustration. FileMaker 16 has removed the toolbar that was displayed at the bottom of the layout windows in previous versions. This toolbar contained the zoom buttons, window mode selection and a toggle for the status toolbar. If you are accustomed to using the status toolbar toggle… you may find yourself at a loss. Fortunately, FileMaker 16 now includes a keyboard shortcut for this toggle. On Windows using Control-Alt-S will toggle the Status Toolbar. On Mac OS Alt-Command-S will toggle the Status toolbar. FM16 Windows - View Menu Notice that the menu commands for Zoom In and Zoom Out also have new keyboard shortcuts in FileMaker Pro 16. In Layout Mode, the button that toggled between vertical and horizontal part labels has been removed. To toggle between vertical and horizontal part labels, simply control-click (Windows) or command-click (Mac) the part label. As well, there is a script step that was introduced in FileMaker 13 “called Show/Hide Menubar”. Using this script step or opening a new window without a menu bar selected will result in a window as seen below. The Status Toolbar hotkey toggle is also very useful in this scenario. FM16 Windows - Hidden File Menu Overall, I think the changes to FileMaker Pro 16 on Windows are a welcome and much needed improvement. Have you noticed any other perks of the new Windows interface? Calvin Cooper is a FileMaker 15 Certified Developer at Skeleton Key. 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.

Card Gallery Sample

FileMaker 16: Card Window

Card-Gallery-Sample The FileMaker 16 Card Window is a new user interface tool which will not only make your application look better, it will help you reuse your layouts. Using the Card Window Style you will be able to display unrelated record data, related record data, and transform the look of currently viewed records. At the same time, it just might make window management easier. Improved New Window Options FileMaker 16 improved the New Window script step interface by placing the Window Style at the top of the setup screen. Prior versions exposed the Window Style option only after selecting the “Specify Advanced Style”. In addition, FileMaker 16 includes a Layout selector within the New Window script step further streamlining the setup process. FM16-New-Window-Default Window Card Option The New Window script step offers the Card style from the drop-down menu. When the Card style is selected, you are given the option to include a “Close” button and to “Dim parent window.” All other Window Options are grayed out for the Card window style: users are unable to Resize, Minimize nor Maximize a window when a Card window is displayed. This also includes the Parent window. Tip: if you opt to exclude FileMaker Pro’s default Close button, make sure you include a way for the user to close the window by including a custom close button or other scripting method. Otherwise your user will get stuck. FileMaker 16 Card Window Style Setup Displaying Unrelated Data One of the exciting uses you will find with the FileMaker 16 Card Window is the ability to display data that is unrelated to the data in the layout of the current parent window without making your users leave their current layout. Why? You could do this to create picker lists for such things as picking: contacts for invoices, contacts for email messages, parts for orders, etc. List View Pickers When using a list view layout, you will most likely want to specify the size (especially the height) of your new window. The default size of the FileMaker 16 Card Window is based on the layout’s window content. The default position is based on the center of the parent window. In the case of a list view where the body part is relatively short, the window would only show one record and be short — not ideal for a picker. Example: Using Layout’s Default Sizes In the following example, the sizes for the Card display will use the defaults which are based on the layout’s sizes…

Card-Layout-Mode

Card Layout in Layout Mode.

Card-Window-Setup-Default

Card will default to layout’s size.

 

Card-Display-Size-Default

Defaults to undesirable size.

Example: Using Custom Sizes In the following example, the Card’s window has been customized to give a more desirable picker window height.

Card’s height has been customized.

Card-Display-Size-Custom

Better picker due to Custom height.

Displaying Related Data The FileMaker 16 Card Window is also available in the Go to Related Record (GTRR) script step giving you another manner in which to display related records from a parent record. Example: Setup GTRR Script Step for Company to Contacts

GTRR-Setup-General

In GTRR options, select “Show in new window”.

GTRR-Setup-Card

Card Window Style selected for GTRR script step.

Example: Using GTRR Script with Card

GTRR-Example-Parent

Parent window with GTRR script for Employees.

GTRR-Example-Card

Related records displayed using Card Window Style.

Transform Current Record View Previous versions of FileMaker Pro Window Styles gave us the ability to display data, related or unrelated, in a new window (Document, Dialog, Floating), however the Card is different. Using the Card window has the feeling of unification, dependency and attachment. The Card creates a canvas for displaying alerts, pickers, call to action and for transforming the display of currently view records.

Card-List-Normal

Normal browsing with thumbnails.

Card-List-Transformed

Card displays enlarged photo gallery.

Things to consider If you are anything like me, you will want to add the FileMaker 16 Card Window to all of your solutions. But before you do, consider the following:

  • For the best unification appearance, that is making the Card window appear it is part of the parent window, it looks best if the parent window is larger than the Card window that will open. A Card window can overlap the parent window.
  • Once a Card window has been opened, the Card window (nor the parent) can be repositioned or resized by the user. The Card window can be manipulated by scripts.
  • The record navigator is only applicable to the parent window; not to the record or records displayed in the Card. This is the tool that shows the current found count, previous record, next record, etc. If your users will need to know how many records are being displayed, you may have to add a custom indication.
  • The Toolbar buttons and options (New Record, Delete Record, Find, QuickFind, etc.) are grayed out when displaying a Card. If your Card solution requires these functions, you may have to add custom buttons to your Card layout, however the Menu commands are available. For example, entering Command/Control + n will create a new record in the context of the Card’s layout.
  • Closing a Card window will commit the data for a record if a record was being edited within the window.
  • You cannot open a Card window within a Card window, however you can open any other type of Window Style (Document, Floating, Dialog). The windows can look a bit unwieldy so make sure it fits a specific use case.
  • Backwards compatibility. If a script that was written with FileMaker Pro 16’s Card window is run in an earlier version of FileMaker Pro (Ex. 15), a Document window will open with the title that was specified in the FileMaker 16 Card window setup.
  • FileMaker 16 Pro/Advanced Card is compatible with solutions hosted with FileMaker Cloud and FileMaker Server 15.
  • FileMaker 16 Card window style is compatible with FileMaker Go, although the behavior is slightly different. If the window option Close is checked, FileMaker Go will not display a Close button, but will allow a user to tap on the parent window to close the Card (a similar behavior to dismissing an open popover). Unchecking the Close button will disable this behavior and require a user to click a button you provide in order to close the Card window.
  • FileMaker 16 Card window style will appear as a virtual window similar to other window styles when using the New Window script step.

Jay Sayers is a FileMaker 15 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.

FileMaker 16: Enhanced Data Viewer

FileMaker 16 Enhanced Data Viewer Animation The Data Viewer in FileMaker Pro 16 Advanced got some much needed attention with this release which can best be described as FAST! Its improved interface will have you working, testing and troubleshooting faster and easier thanks to the Auto-Complete, Search and Automatically Evaluate tools. Auto-Complete FileMaker 15 introduced Auto-Complete to many areas of the application, however it was sorely missed in FileMaker Pro Advanced’s Data Viewer. The Data Viewer is where playing, testing and troubleshooting is done without having to make changes to the database. With FileMaker 16 Advanced Data Viewer, you can begin typing the table, field or function name you want and the appropriate list will be presented with lightning speed. FileMaker 16 Advanced Data Viewer Auto-Complete Automatically Evaluate One…two…three…who knows how many fewer clicks this feature will give you, but it could be quite a few. When typing out a simple calculation, it can be nice to see the result as soon as the calculation is completed. Without having to click the “Evaluate” button. FileMaker 16’s Data Viewer includes an Automatically Evaluate checkbox feature. I would like to give special kudos to FileMaker, Inc. for getting this right. Instead of forcing this feature on every developer for every calculation, the option to turn it off is there too. This is especially helpful for long or complex calculations such as ExecuteSQL statements. FileMaker 16 Advanced Data Viewer Automatically Evaluate Search Boxes FileMaker 16 Advanced Data Viewer did not just get one…it got two new search boxes. Now you can search for or filter field names in tables and function names. This will end up being a huge time saver. Think about the next time you inherit a FileMaker database file with 600+ fields in one table! FileMaker 16 Advanced Data Viewer Search Boxes Resizable The space in the middle of the screen, the Expression and Result, is now resizable. So if you need more Expression space and less Result space, drag it! Screen real estate can also be gained with the addition of the Show/Hide function pane button in the upper right-hand corner. This can be handy if you rely on the Auto-Complete function or your knowledge of the available functions. Sort and Filter Finally we wrap up with one more addition and one modification to the Data Viewer of FileMaker Pro 16 Advanced. You can sort the fields for the table being displayed without having to leave the Data Viewer. By clicking on the sort icon, you order the fields by Creation Order, Field Name, Field Type or the Custom order that was set while in the Manage Database dialog. FileMaker 16 Advanced Data Viewer Field Sort Tool The function category drop-down list was changed to use a sort button which presents the same familiar list from versions past. This was done to allow for the function search tool as mentioned earlier. FileMaker 16 Advanced Data Viewer Category Selector You will find the adjustments made to the FileMaker Pro 16 Advanced Data Viewer will make your work easier and more enjoyable. Day by day. File by file. Jay Sayers is a FileMaker 15 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.

fmp16 adv icon

FileMaker 16: New JSON Functions

One of the highest community voted features making its way into the release of FileMaker 16 is a new set of functions dedicated to the parsing of JSON (JavaScript Object Notation) text strings. These come in conjunction with the introduction of REST API into the FileMaker Server software, and serve as a new valuable tool for developers to communicate with third party data sources. JSON holds a demanding position as an industry standard in web services. Now, where FileMaker developers used to have to turn to custom functions and/or third party plugins to interact with these services, they will have use of standard built-in functions that will ship with FileMaker 16. The NEW Functions

  • JSONDeleteElement( json ; keyOrIndexOrPath ) – Deletes a JSON data element specified by an object name, an array index, or a path.
  • JSONFormatElements( json ) – Formats elements in JSON data to make them easier to read.
  • JSONGetElement( json ; keyOrIndexOrPath ) – Queries JSON data for an element specified by an object name, an array index, or a path.
  • JSONListKeys( json ; keyOrIndexOrPath ) – Lists the object names (keys) or array indexes in JSON data for an element specified by an object name, an array index, or a path.
  • JSONListValues( json ; keyOrIndexOrPath ) – Lists the values in JSON data for an element specified by an object name, an array index, or a path.
  • JSONSetElement( json ; keyOrIndexOrPath ; value {; valuetype } ) – Adds or modifies an element in JSON data specified by an object name, an array index, or a path.
  • SortValues( values { ; datatype } )Sorts a list of values based on the specified data type and locale.
  • UniqueValues( values { ; datatype } ) – Returns unique values that are in a list based on the specified data type and locale.

…other NEW utility functions

  • CryptDigest( data, algorithm ) – Returns a binary hash value generated by the specified cryptographic hash algorithm.
  • CryptAuthCode( data, algorithm, key ) – Returns a binary HMAC (keyed-hash message authentication code) using the specified cryptographic hash algorithm.
  • Base64EncodeRFC( RFC number, data ) – Returns data as text in the specified Base64 format.
  • HexEncode( data ) – Returns data as text in hexadecimal format.
  • HexDecode( data {; fileNameWithExtension } ) – Returns either container or text content from text encoded in hexadecimal format.
  • TextEncode( text ; encoding ; lineEndings ) – Returns a text file as container data from text using the specified character encoding and line endings.
  • TextDecode( container ; encoding ) – Returns text decoded from container data using the specified character encoding.

The new utility functions have been included to maximize FileMaker’s ability to talk to REST APIs by providing tools for signing and encoding JSON data based on the requirements of specific APIs. They each have situations where they would be very useful, however specific examples of their uses will not be covered within this article. Parsing data out of JSON These first functions are designed for pulling desired data out of a JSON text string. The first parameter is always the string itself while the second parameter designates what specific data is desired. The result of these functions is text, but is NOT itself a valid JSON string. For the purposes of all the following examples any reference to the $$JSON variable can be assumed to be populated with the sample block of JSON data provided by the FileMaker documentation here. JSONGetElement() Example 1

  • JSONGetElement (“{ “a” : 10, “b” : 11, “c” : 12 }”; “b” )
  • Returns 11

Example 2

  • JSONGetElement (“[“lion”, “tiger”, “bear”]”; 1 )
  • Returns tiger

Example 3

  • JSONGetElement ($$JSON; “bakery.product[1]id” )
  • Returns FB1

(Notice how this example demonstrates how to format a request for a value within a nested object) JSONListKeys() Example 1

  • JSONListKeys (“{ “a” : 10, “b” : 11, “c” : 12 }” )
  • Returns a¶b¶c

Example 2

  • JSONListKeys ( $$JSON ; “bakery.product” )
  • Returns 0¶1¶2

JSONListValues() Example 1

  • JSONListValues (“{ “a” : [“First”, “Middle”, “Last”] }”; “a” )
  • Returns First¶Middle¶Last

Modifying/Producing JSON These next functions are available for creating and/or modifying JSON. The first parameter is an existing JSON string (or simply “{}” in the case of JSONSetElement(), allowing for the creation of a new string). The result of these functions is a valid JSON text value. JSONDeleteElement() Example 1

  • JSONDeleteElement (“{ “a” : 10, “b” : 11, “c” : 12 }”; “b” )
  • Returns { “a” : 10, “c” : 12 }

Example 2

  • JSONDeleteElement (“[“lion”, “tiger”, “bear”]“; 2 )
  • Returns [“lion”, “tiger”]

JSONFormatElements() Example

  • JSONFormatElements (“{ “a” : { “id” : 42, “Description” : 34 } }”)
  • Returns

{   “a” :{    “id” : 42,    “Description” : 34   } }

JSONSetElement() Example 1

  • JSONSetElement (“{ “a” : 10, “c” : 12 }”; “b”; 44; JSONNumber )
  • Returns { “a” : 10, “b” : 44, “c” : 12 }

Example 2

  • JSONSetElement (“[“lion”, “tiger”, “bear”]”; 1; “sheep”; JSONString)
  • Returns [lion, sheep, bear]

(Notice that the count of values within an array starts with “0” designating the first value) JSON has six types of values. These types are designated within a fourth parameter of the JSONSetElement function. 1. JSONString 2. JSONNumber 3. JSONObject 4. JSONArray 5. JSONBoolean 6. JSONNull Example 3

  • JSONSetElement (“{}”; “a”; “[1,2]”)
  • Returns {“a”:[1,2]}

Example 4

  • JSONSetElement (“{}”; “a”; “[1,2]”; JSONString )
  • Returns {“a”:”[1,2]”}

Example 5

  • JSONSetElement (“{}”; “a”; “[1,2]”; JSONNumber )
  • Returns {“a”:12}

Example 6

  • JSONSetElement (“{}”; “a”; “[1,2]”; JSONObject)
  • Returns {“a”:{}}

Example 7

  • JSONSetElement (“{}”; “a”; “[1,2]”; JSONArray)
  • Returns {“a”:[1,2]}

Example 8

  • JSONSetElement (“{}”; “a”; “[1,2]”; JSONBoolean)
  • Returns {“a”:true}

Example 9

  • JSONSetElement (“{}”; “a”; “[1,2]”; JSONNull)
  • Returns {“a”:null}

Value Lists Lastly, two new functions allow for the manipulation of value lists. These can also reference the data types listed above. SortValues() Example

  • SortValues ( 5¶15¶10¶20; -2 )
  • Returns 20¶15¶10¶5

UniqueValues() Example

  • UniqueValues ( Flowers::Colors )
  • Returns red¶blue¶yellow (when the Flowers::Colors field contains red¶blue¶yellow¶blue )

For additional information about JSON in general see http://www.json.org. Some samples listed here are based on those provided by FileMaker within the FileMaker 16 documentation Jeremy Upton is a FileMaker 15 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.

FileMaker 16: The FileMaker Data API

REST comes to FileMaker

While we have been able to use plugins and the Insert from URL script step to consume data from other web-based systems using either SOAP or REST services, FileMaker did not have a native way to easily serve its data to other sites. There is custom web publishing, and ODBC connections, but that was still somewhat limiting when it came to serving data to other web-based systems from anywhere in the world. That all changes in FileMaker 16 with the introduction of the REST based Data API. Now your FileMaker solution can behave like any number of other databases from around the globe who have distinct APIs written for external users to consume the data. Please note that FileMaker considers this a “trial feature”, so it may not be completely ready for prime time. Additionally, within the FileMaker 16 Server Admin Console, there is a new tab enabling and configuring the Data API that alludes to the possibility that somehow data connections may be metered in the future. So if you are trying to provide a high capacity site, note there may be future charges related to the number of API calls to FileMaker Server. Even with these unknowns and certainly some limitations, like not being able to run a script, that come with any first release, the core of this looks very interesting.

Getting Started – The Very Basics

Here is a quick list of things to consider when planning for the new Data API.

File Basics

  • Separate Layout or Separate File: Not unlike Custom Web Publishing (CWP) the Data API can only interact and access the fields on a specified layout so you must create a layout and include only those fields needed for your intended calls.
  • Authenticated Accounts only: The Data API requires a fully authenticated account to access the data. Thus, you can not make a straight URL call to access the data in a FileMaker database like you could for say Yahoo Weather.  Not only does the API require authentication via FileMaker or the new Oauth feature, but once authenticated you will receive a token that must be used for all subsequent data calls.
  • New Extended Privilege: Not only must you use an authenticated account, but that account must have the new fmrest extended privilege attached to it.
  • JSON Rules: Whether it is a POST, GET, PUT, or DELETE, the REST parameter or payload must be JSON-formatted text. Therefore you will need to learn how to write out the JSON data when trying to update data in your system as well as read the data when pulling data from your system.

Server Basics

  • Separate Configuration: As mentioned previously there is a new tab in the FileMaker 16 Admin Console that allows you to enable the REST API.
  • SSL Required:  The FileMaker Data API requires SSL encryption so that must be enabled on your server.
  • The URL Please:  To access the Data API your url will look something like – https://www.mysolution.com/fmi/rest/api/ (then either auth, record, find, or global) /the solution name / layout name/

Where to Go Next

Clearly there is more to learn, understand and set up from a client perspective but now any website or app that uses JavaScript, PHP, .NET, C, JAVA (just to name a few) can be given the keys to directly access your data in FileMaker. With FileMaker Cloud, Custom Web Publishing using XML or the FileMaker API for PHP is not supported. The FileMaker Data API will be the future for interacting with solutions hosted with FileMaker Cloud or FileMaker Server. FileMaker 16 also introduces native JSON functions across the entire platform. JSON and REST APIs are quickly becoming the data interchange standard across the internet. As FileMaker continues to develop their Data API feature, the possibilities for using REST in external sites, between FM solutions, within web viewers and even through mobile apps truly remain endless. Here at Skeleton Key we are excited about the possibilities and look forward to writing future posts about our experiences implementing this technology in real-world solutions. Todd Stark is a FileMaker 15 Certified Developer at Skeleton Key. 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.

screenshot 476

FileMaker 16: Layout Objects Window

Once upon a time FileMaker layouts were simple. Everything was visible all of the time and unless it was done by mistake, we never stacked objects on top of one another. Over the years however, a lot of features have been added to FileMaker to help us get the most out of small screens. These days we have tools such as tab controls, slide controls, pop-overs and object hiding that allow us to cram lots of objects into a small amount of space and show the users just those that we want them to see. These features allow us to do things that used to be impossible, but with so many objects on a layout it can be difficult to find the one you are looking for. To help us with this, FileMaker 16 adds a feature called the Layout Objects window (LOW). Here’s how it works. To open the Layout Objects window go to Layout mode, open the “View” menu and select “Layout Objects” or use the Layout Objects button in the Status Toolbar to show or hide the window. screenshot_470 Before we talk about how the Layout Objects window works it’s important that you understand the concept of the stacking order and how it affects objects on a layout. As we place objects onto a layout we see them as a two dimensional image, but behind the scenes FileMaker is actually stacking these objects on top of one another with the first object we placed going on the bottom and each subsequent object going on top of it. This is easy to see when objects overlap one another, but it’s important to remember that even when objects aren’t overlapping they are still assigned a place in the stack. FileMaker has provided commands to move objects forward and backward in the stack for many years, but until now there has been no way to see where an object was located in relation to all of the other objects in the stack. When you open the LOW it shows a list of all objects on the layout sorted in their stacking order with the objects closest to the front showing at the top. You can reorder objects in the stack by clicking and dragging them. screenshot_471 Clicking on an object in the LOW will select that object on the layout, but even though its handles will become visible the object may be hidden if there are overlapping objects that are ahead of it in the stacking order.     To make an object visible without changing its position in the stacking order you can right click on it in the LOW. This displays a menu that will allow you to hide all of the other objects on the layout or just those that overlap the object. When an object is hidden an indicator will be displayed to the right of its name in the LOW and you can show or hide individual objects by clicking on this indicator. screenshot_476 You can tell the object’s type by looking at the icon on the left side of each line and you can use the filter icon at the top of the window to show only objects of a certain type. If you have assigned a name to an object that name will be displayed on its line in the LOW. If no name has been assigned then a description of the object will be shown instead. Some objects in the LOW will appear as a group either because they are inside another object that automatically makes a group out of them, such as a portal, button bar or tab control, or because a developer has used the Group command on multiple separate objects. In either case these objects will appear together under a heading that identifies the group itself. The LOW will allow you to reorder objects within a group, but you can’t drag objects into or out of the group using the LOW. Also, if you change the position of the group object within the stacking order all objects in the group will be moved. Now that FileMaker has provided us with the LOW it should make it much easier to find the proverbial needle in the haystack that our layouts can sometimes become. I look forward to all of the questionable development decisions I will soon be making knowing that I have this tool to bail me out. Alan Kirtlink is a FileMaker 15 Certified Developer at Skeleton Key. 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.