Jump to content

  •  

Photo

Executing Find and returning to the very same record


  • Please log in to reply
3 replies to this topic

#1 Buckie  newbie

Buckie
  • Members
  • 50 posts
  • FM Application:11
  • Time Online: 9h 50m 57s

Posted 18 July 2014 - 12:54 PM

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.


  • 0

#2 BruceR  consultant

BruceR
  • Members
  • 3,360 posts
  • LocationRedmond WA
  • FM Application:13 Advance
  • Platform:Mac OS X Mountain Lion
  • Skill Level:Expert
  • Certification:9, 11, 12
  • Membership:TechNet
  • Time Online: 33d 19h 48m 23s

Posted 18 July 2014 - 01:29 PM

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.


  • 0

#3 Buckie  newbie

Buckie
  • Members
  • 50 posts
  • FM Application:11
  • Time Online: 9h 50m 57s

Posted 18 July 2014 - 02:19 PM

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.


  • 0

#4 comment  consultant

comment
  • Members
  • 24,464 posts
  • Time Online: 340d 16h 41m 16s

Posted 20 July 2014 - 06:20 AM

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.


  • 0




FMForum Advertisers