April 11, 200223 yr hello, in the invoicing system i am working on, i am not using the FMP status area, i have made my own. on the Find layout i have duplicated the everything successfully but the 'omit' check box. maybe i am not getting the script steps in the correct order. i have a yes/no field called 't Flag Omit' and when checked i would like my search to use the 'omit' function in the search. i realize i need a if/then statement in my Perform Search script, but how do i go about doing this? thanks.
April 11, 200223 yr quote: Originally posted by Ken Edwards: hello, in the invoicing system i am working on, i am not using the FMP status area, i have made my own. on the Find layout i have duplicated the everything successfully but the 'omit' check box. maybe i am not getting the script steps in the correct order. i have a yes/no field called 't Flag Omit' and when checked i would like my search to use the 'omit' function in the search. i realize i need a if/then statement in my Perform Search script, but how do i go about doing this? thanks. After performing find add these script steps code: if(FlagOmit) ShowOmitted end if Hope your FlagOmit is an global Also you should capture error since it's an FindScript: Dj
April 11, 200223 yr Did you say Find Layout? So you're already in find mode when trying to set FlagOmit to true? Dj
April 11, 200223 yr Watch out here ! If you have LOCKED the status area as hidden then you can't use the omit - even when scripted. I could have ripped Dominic Goupille's head off for that !
April 11, 200223 yr quote: Originally posted by Mark Dore: Watch out here ! If you have LOCKED the status area as hidden then you can't use the omit - even when scripted. I could have ripped Dominic Goupille's head off for that ! If you wanted to say with multiple find requests than you're right. For single Find Request that is not a true! Dj
April 11, 200223 yr Author quote: Originally posted by dj: Did you say Find Layout? So you're already in find mode when trying to set FlagOmit to true? Dj yes i am in find mode already. i will give this a go tonite when i get time. that thing about the locked status area sounds pretty dumb. thanks for the info all.
April 14, 200223 yr dj, your solution works if you only have one find request. If you want "the full options" with as many find requests (omitting or not) you want, you could do as following: (I suggest that you have a search script that activates the search mode an pauses for input). you need a number field "one" (not a global!), filled with "1" in every record (is anyway usefull for many other things...). In your "find layout", put this field as a checkbox, performing the script: set field ( one , Case(IsEmpty one) , 1)) omit record have fun Gerd
April 15, 200223 yr quote: Originally posted by Gerd Muller: dj, your solution works if you only have one find request. If you want "the full options" with as many find requests (omitting or not) you want, you could do as following: (I suggest that you have a search script that activates the search mode an pauses for input). you need a number field "one" (not a global!), filled with "1" in every record (is anyway usefull for many other things...). In your "find layout", put this field as a checkbox, performing the script: set field ( one , Case(IsEmpty one) , 1)) omit record have fun Gerd Right , but just one thing, if you want to change the status of current find request (from omit to inclusion and viceversa) you should change script to set field ( one , Case(IsEmpty one) , 1,"")) omit record where "" stands for inclusion [ April 15, 2002, 02:58 AM: Message edited by: dj ]
April 15, 200223 yr dj, both ways will be ok. Since you can leave away the default result in a case function, you will get a "" so or so. And Mark: I tried this with the locked and hidden status bar: and it worked (FM 5.5v2 Mac). Probably, somebody at FM had the ears wide open have fun Gerd
April 16, 200223 yr Author thanks everyone for their input. i been so busy working on other modules of this solution i have yet to get back to implimenting this omit feature. its on my 'to do' list. great help,. thanks!
Create an account or sign in to comment