Password Input Masking

Version 2

     

    Script

     

    Compatibility
    Creator
    Mac OS X, Windows
    Todd Duell
    FMP 10, 11
    Formulations Pro
    Web: No
    File Type: FP7
    Server: No
    FileSize: ~ .68 megabytes
    http://www.formulationspro.com

    Description

    I've created a number of solutions for password input masking. None of them have been entirely clean or dynamic because they really needed a trigger to manage the process appropriately. Now that FileMaker Pro 10 has triggers we can finally do input masking the way it was intended to be performed. This technique is nothing more than the onObjectModify trigger and a few simple Set Field By Name calculations that use an old-school technique to identify the position of the cursor in a Mask field. I've also included an Alternative Technique script that uses a simple Show Custom Dialog script step that performs the same exact process with far less overhead for those of you that are not as comfortable with the core FileMaker concepts used in this article. The only downfall is that it's not dynamic. However, I bet that you don't have more than one password input masking requirement in any of your files. So I have to ask the question — why do it the hard way? Sometimes the simple approach works just as well. However, if you're like me, I'm sure you're also interested in improving your FileMaker skills so you can apply them to other solution.

     


    Code

     

    Sample Input

    Sample Output


    Developer's Notes

    See sample file for full demo and technical article.

     


    FileMaker Inc. provides this content on an “As Is” basis, without any warranty, and subject to the terms of the FileMaker Technical Network Agreement. FileMaker makes no representations and is not liable for any content or related information. You may use the content as part of your own solutions and for your customers, but you may not otherwise publicly distribute any content that you did not submit. ©2009-2011 FileMaker, Inc. All Rights Reserved. FileMaker is a trademark of FileMaker, Inc. registered in the U.S. and other countries.