
Auto Quick Find
by Jeremy BanteOverview
Auto Quick Find is a single set of simple scripts that developers can use for find-as-you-type functionality in any context with minimal set-up. Unlike other existing approaches, this module improves perceived responsiveness by only performing finds during pauses in typing, so users don’t have to wait for find results after. Every. Keystroke.
Dependencies
Find field layout objects for each layout need to be named “AutoQuickFindField.” Solutions needing Find results to be sorted can accomplish that through OnModeEnter script triggers, which will be tripped by Auto Quick Find specifically for this purpose.
License
Anyone may do anything with this software. There is no warranty.
Download
Download Auto Quick Find from Github. If you are not comfortable working with GitHub, you can download the repository directly.
[…] Modules ). mFM Modules provide features like Navigation Bars, Transaction Frameworks, search utilities , SQL helpers, etc. These are all below the level of application or solution. Essentially any […]
This is a great module. Thanks Jeremy!
Cool module. I modified it a bit to fit my structure, but everything works fine. Thanks.
This is a great module. Thanks for putting it out there for all of us to use. It would be cool to see, either as added functionality here or as a separate module, a popup picker similar to the one described at filemakerhacks (http://www.filemakerhacks.com/?p=1731).
Tom – I have just finished implementing a picker system into a solution using the virtual list technique. It also incorporates the auto quick find module. I have two scripts to populate the virtual list dependent on the need. One script will populate the list using all items in the table, and one will populate based on some other query parameter. For instance, if you want to show locations for the currently viewed customer only. Works really well. When I have a chance, and with Jeremy’s blessing, I will see if I can mold this into a module.
Go for it, Bob. The license begins, “Anyone may do anything with this software.”
Bob, thanks a lot. I’ve used your technique in a couple of my projects and it works great. It does require a bit of tinkering, though, to adapt it; that’s why I thought it would be cool to see it as a module.
Bob, I’m looking for a picker system, I hope you can as soon as you are ready, Thanks
HI Jeremy,
I’ve been trying to get a picker interface working with your module, but am running into trouble. My script opens a new window and goes to the Auto Quick Find layout and then uses the pause indefinitely script step, to allow the user to type in a search query. The Auto Quick Find OnObjectModify script is getting triggered and running, but the search doesn’t seem to be executing; nothing happens as the user types the query. I’m afraid I haven’t been able to figure out what the problem is. Auto Quick Find works flawlessly when I manually open the layout instead of doing so via script with the pause indefinitely script step.
Thank you,
Tom
Tom, the Auto Quick Find module performs its Quick Find with an OnTimer script trigger. OnTimer triggers will not fire while another script is paused. Tweak your workflow so that there is no script paused while the user is performing their search in the new window; the new modal dialog advanced window style in FileMaker 12 addresses the main reasons motivating that technique.
Thank you, Jeremy!
[…] via Modular FileMaker | Auto Quick Find. […]
[…] Modules ). mFM Modules provide features like Navigation Bars, Transaction Frameworks, search utilities , SQL helpers, etc. These are all below the level of application or solution. Essentially any […]
I just added this to a project and it works great, thank you very much. The only small quibble is if you spell something wrong and click into the field to correct it. The current script bounces the cursor to the end of the field after each letter triggers the refresh. I tweaked your script to take care of this.
Set a variable at the start of the QuickFind Trigger refresh script
$Sel = Get(ActiveSelectionStart)
then modify the QuickFind settings script using the set selection command rather than the go to field command
Set selection = QuickFindField, Start Position: $Sel; EndPosition: $Sel-1
With this small tweak its much cleaner as i tend to make a lot of spelling mistakes!
Thanks again for a great module.
Hi Jeremy
Can Auto Quick Find work in a portal or a Popover with a portal in it…
rl
Robert, I don’t currently have plans to add portal filtering to the module.
Robert,
For similar results for a portal filter, you could modify the script to replace the QuickFind script steps with a routine of commit, refresh portal, and go back into your filter field. I would recommend implementing Mike’s tweak, just above your comment to put the cursor back where it belongs.
I’ve used the technique outlined here in the past: http://filemakerinspirations.com/2010/10/dynamic-portal-filtering-while-you-type/
Good luck!
-Shawn
This is amazing! Thank you so much for this!
Theres a fault with this in webdirect where its putting the cursor behind the value typed. Is there a fix for this?
Cheers
Hello All,
I got the same problem with Steve. Anyone have fixed this problem?
Thank you.
It seems like under FileMaker Pro v16 (16.0.2, specifically), searches are not reliably being triggered. Anyone else notice this?