AnsweredAssumed Answered

Script Question with Auto Insert and date

Question asked by user14040 on Jun 3, 2012
Latest reply on Jun 4, 2012 by user14040

Title

Script Question with Auto Insert and date

Post

Hi

 

Trying to create a script that will auto insert text on certain dates. ( Still learning how to create scripts on my own)

What I want to do is auto insert "Pending" into a drop down field on dates less than 15 (Insert "Pending" between 6/1/2012 to 6/14/2012)

 

And then what I want to do is auto insert "Yes" in drop down field on dates 15th and above.

 

This is the script I have and it seems to work but I wont really now until the 15th.  Right now it is inserting 'Pending" when a new record is created.  But will it insert Pending on the 15th and above?

 

My Script:

New Record/Rrequest

If[Get(CurrentDate) ≥ "15"]

Insert Text[Select;Glassware::ChargeForService; "Pending"]

Commit Record/Request[Skip data entry validation;No dialog]

Go to Next Field

Else If[Get ( CurrentDate )   ≤   "15"]

Insert Text[Select;Glassware::ChargeForService; "Yes"]

Commit Record/Request[Skip data entry validation;No dialog]

Go to Next Field

End If

 

Just want to know is if this script will do what I need it to do or do I have to change it.  

 

Thanks

Outcomes