4 Replies Latest reply on Apr 3, 2012 10:48 AM by splinx001

    FM Pro v. 11 Date Pop-up Reminder

    ahutler

      Title

      FM Pro v. 11 Date Pop-up Reminder

      Post

      I would like to have a reminder pop-up when opening up the Database that after 3 years from the date entered into a certain field.

       

      For example on object comes into the office and I have to enter it into the database.

      I created a  field which is called "Date Received" ( should this be a "Date" field?)

      I enter today's date    06/29/2010

      On 6/29/2013 I want to open the database and have a pop-up reminder that this object was received 3 years ago.

        • 1. Re: FM Pro v. 11 Date Pop-up Reminder
          philmodjunk

          I created a  field which is called "Date Received" ( should this be a "Date" field?)

          Absolutely,.

           

          Will the notification date always be three years or could it vary for different objects?

           

          If it's always 3 years, you can write a script that perfoms a find for all records with a date recieved 3 year or more older than today's date.

           

          Enter Find Mode[]

          Set Field [YourTable:: DateReceived ; "< " & let ( d = Get ( CurrentDate ) ; Date ( day ( d ) ; Month ( d ) ; Year ( d ) + 3 )]

          Set Field [YourTable:: Acknowledged ; 1 ]

          set Error capture [on]

          Perform find[]

          If [Get (foundcount) > 0 ]

             Show Custom Dialog["These items were received 3 or more years ago..."]

          End IF

           

          I've added an Acknowledged field so that you can check off those items for which you've already been notified so that they don't keep popping up.

           

          You can use File Options to specify that this script run each time you open the database and a variation of this approach can be used when the notification date varies from item to item.

          • 2. Re: FM Pro v. 11 Date Pop-up Reminder
            splinx001

            OK Im trying to find something that is similar to what ebethram asked almost 2 years ago but im wanting the date field to pop the message up on or after the date specified in the Exclusive_Exp field.  I've tried > and < and < and > but no luck. Im terrible at scripting so I'm probably missing something minuet.  Any help would be greatly appreciated! Laughing

             

            Enter Find Mode[]

            Set Field [YourTable::Exclusive_Exp ; " = " & let ( d = Get ( CurrentDate ) ; Date ( day ( d ) ; Month ( d ) ; Year ( d )))]

            set Error capture [on]

            Perform find[]

            If [Get (foundcount) > 0 ]

               Show Custom Dialog["Exclusivity for these images has expired. Take action!"]

            End IF

            • 3. Re: FM Pro v. 11 Date Pop-up Reminder
              GuyStevens

              How about this:

              Enter Find Mode [  ]
              Set Field [Expdate_Test::ExpDate; "< //"]
              Perform Find[  ]

               

              The "< //"
              will search for a date that is older then today's date.
              // = today's date.


              Would that work?

               

              • 4. Re: FM Pro v. 11 Date Pop-up Reminder
                splinx001

                YES!!! You sir, are a mad genius!!! It worked and it was a simple, straight forward answer!!! Thanks again!!! Laughing