surlyb Posted July 13, 2000 Posted July 13, 2000 I am a FM neophyte. I have a database of records. The first field is the day I entered the information in the database. There is another field for the company name. What I would like to do, is to write a script that will 1) search for a specific company name, and 2) then alert me when 60 days have passed since I entered that record into the database.
yafreax Posted July 14, 2000 Posted July 14, 2000 in theory, this should work, and it sort of does. i was running it on open: go to first record, Loop If [DateToText(day entered) < DateToText(Today- 60)] Omit record End If Goto next record Exit Loop if (Status(CurrentRecordID)=(Status(CurrentRecordCount) End Loop Show omitted records then i had it pop up a message that said these records have been in longer than 60 days or whatever. Problem is, it would only find 3 out of the 6 that it should've found (actually, it was omitting them, but same difference here). I haven't spent long on this, only about twenty min., but maybe this will give you an idea of what should work, theoretically (that is if my understanding of the DateToText function is correct). And if anyone out there could explain to me why it doesn't work, i'm sure both of us would appreciate it. you also might want to mess around with a field that calculates Today's date - 60 days which is just DateToText(Today)-60. Good Luck
Vaughan Posted August 10, 2000 Posted August 10, 2000 Instead of the "Today" function, use "Status(CurrentDate)" it seems to be much more reliable.
Vaughan Posted August 24, 2000 Posted August 24, 2000 Why use a looped script at all. Create a field that calculates the "age" of the record -- use the Status)CurrentDate) function rather than Today. Then perform a simple Find and you have them.
Recommended Posts
This topic is 8862 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