Mark Reed Posted June 5, 2009 Posted June 5, 2009 I have a button that toggles between showing omitted records and the found set. I would like to have a text box show that says "SHOWING OMITTED RECORDS" or "SHOWING SELECTED RECORDS" when I toggle back and forth. I cannot find a way to do this. Any ideas?
comment Posted June 5, 2009 Posted June 5, 2009 Well, when you select 'Show Omitted Only' the omitted records become found and the found set becomes omitted. There is no special status of "now showing omitted", as far as Filemaker is concerned - it is ALWAYS showing the current found set. So to achieve your goal you'd need to restrict this action to a script that (a) switches between found and omitted, and ( toggles a status indicator, e.g. a global field or variable.
mr_vodka Posted June 5, 2009 Posted June 5, 2009 (edited) I am not sure if that will make real sense when showing omitted is not really a status. It is more like an action. FileMaker doesnt really distinguish between what your last found set was and the rest which make up the omitted records if you switch their place. IOW, a crude way of looking at it is that when you show omitted, it just switches the found set for the non-found set. Now you may be able to create a way to capture when a scripted or manual find was done and set some kind of global variable as a flag but I dont really see the juice worth the squeeze IMHO. *Edit - Didnt see Michael's response. Edited June 5, 2009 by Guest
Mark Reed Posted June 5, 2009 Author Posted June 5, 2009 ahhh I see... so... if it just moves between found/unfound, and I have a toggle button, I could do some type of IF statement to set a variable back and forth between "on" and "off" and possibly do a conditional format to a label? Im new to all of this, but its slowly starting to make sense.
Mark Reed Posted June 5, 2009 Author Posted June 5, 2009 the reason I need to display found and unfound is that the user will be displayed a list of items... they can choose to omit each item before printing the catalog. I have a toggle so the user can see what items have been omitted, and choose to add them back if they desire. I would like to show if they are looking at the found or unfound set incase they get distracted and come back to not know where they left off - what side of the fence they are on per say. Im struggling with a script that would set a global to 0 or 1 each time the button is toggled, but I cant get it working.
comment Posted June 5, 2009 Posted June 5, 2009 I have a toggle so the user can see what items have been omitted, and choose to add them back if they desire. As long as the process is scripted-only (i.e. users cannot select 'Show Omitted Only' from the menu), it should work. To toggle a global field between 0 and 1, set it to: not gField Hint: if you place an instance of the global field in the body, and format it as Boolean, it can serve as a button label, toggling automatically between "Omit' and 'Restore'.
Mark Reed Posted June 5, 2009 Author Posted June 5, 2009 over lunch I thought of a different approach and wanted to run it past you guys... what about instead of trying to toggle and display... on the selection layout that shows the found set - they click omit.. and the records get removed. I have a button that says Show Omitted and when clicked it takes them to a different layout (that says OMITTED) and "shows omitted records"... those omitted records become the found set then... I have a button that says return to selected records... which shows omitted records (thereby returning to the orignal found set) and goes back to the original layout... does that make sense? any thoughts on that approach?
comment Posted June 5, 2009 Posted June 5, 2009 It's almost the same thing - two layouts, or one layout that changes appearance. Personally, I'd prefer to minimize the number of layouts, and avoid having to duplicate any changes.
Recommended Posts
This topic is 5649 days old. Please don't post here. Open a new topic instead.
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 accountSign in
Already have an account? Sign in here.
Sign In Now