November 17, 200025 yr Newbies I have three layouts. Layout "A" contains records with a start date and a finish date. Layout "B" is a find layout. Layout "C" is a summary layout. On my "B" layout, I have buttons that find records within a given range from the current date (ie. "within 30 days", "within 60 days", and "within 90 days".) Let's say I click on the "within 30 days" button on the "B" layout. I want a script that performs the following: Go into the "A" layout, find all Start Dates of the records that are within 30 days of the current date, and show those records on the "C" layout. The date format of the "A" layout is mm/dd/yyyy.
November 17, 200025 yr I think I can help. Here is an example using a 30 day request: Goto Layout "A" Enter find mode Paste Current Date (select date field you are searching) Paste Literal (do NOT select entire contents, "...") Paste Result (do NOT select entire contents, select date field, "Today + 30") Perform find Goto Layout "C" You can use the same example for 60 and 90 day searches. You could also shorten the script by performing the appropriate find 1st and then simply "Perform find" and restore find requests. Of course you would still need to switch layouts. Hope this helps! JM [This message has been edited by JM (edited November 17, 2000).]
November 18, 200025 yr quote: Originally posted by JM: I think I can help. Here is an example using a 30 day request: Goto Layout "A" Enter find mode Paste Current Date (select date field you are searching) Paste Literal (do NOT select entire contents, "...") Paste Result (do NOT select entire contents, select date field, "Today + 30") Perform find Goto Layout "C" Do NOT use the Today function. Use the Status ( CurrentDate ) function instead. You pay dearly for use of the Today function and I find that there is no longer a need for it. Just say no. Basically the Today function calls a internally stored calculation that is stored in every record of your DB. This recalculates everytime you open the file. Status ( CurrentDate ) gives the same result, but is not stored and only calculated once as you use it. ------------------ =-=-=-=-=-=-=-=-=-=-=-=-= Kurt Knippel Consultant Database Resources mailto:[email protected] http://www.database-resources.com =-=-=-=-=-=-=-=-=-=-=-=-=
November 21, 200025 yr Author Newbies Thanks JM. It worked like a charm. I just substituted the "Paste Literal" with "Insert Text" because I'm using FileMaker 5. Thanks for the help.
Create an account or sign in to comment