Sign in to follow this  
Followers 0

Executing Find and returning to the very same record

4 posts in this topic

Posted

Help me out guys, I'm probably missing something obvious?

 

Here's the problem: a user can only access a certain set of records, other records marked with "no access". Said user often performs searches and likes to do a "show all" command to see the full picture from time to time. What I cannot do is subvert the show all command to make FM display the current record while filtering out the rest. As we all know it's easy to filter out "no access" records by running a simple find, however that has a side effect of returning you to the very first record while I want to stay where I was! I've tried everything: constrain, extends, even loops - they don't work as I need. "Go to Record" doesn't work because the record number it uses always changes. Short of creating a relationship is there a way around with a script? Ideally I'd love to see something like "go to unique record id" step but can't find anything like that in FileMaker.

Share this post


Link to post
Share on other sites

Posted

If you have FileMaker Advanced you can define custom menus.

 

This allows you to define and "hijack" what the find all command does.

 

If instead it performs a find "*" on, for instance, an ID field, then the resulting record set shows only the records the user is allowed to see.

Share this post


Link to post
Share on other sites

Posted

Well, yes, I know that of course, sorry I wasn't clear enough. The problem is returning to the same exact record after performing a find.

Share this post


Link to post
Share on other sites

Posted

I don't know of a really good solution for this. Ideally, Extend Found Set[] should leave you with the current record being the same as the one before (as is the case with Show All Records). Alas, Filemaker doesn't think so - so you need to do something extra to return to the previous current record. That "something extra" could be either GTRR (as you already mentioned) or looping until you find the correct record (which you have remembered by storing either its serial ID or RecordID in a variable).

 

In version 13, you could eliminate the looping by calculating the ordinal number of the remembered ID within a [List of] summary.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0