February 2, 200619 yr Hi, I have a field that gives the user a choice of finding their jobs based on what they select from the field... Today Tomorrow 2 Days 3 Days Then I made a button that starts a script to find and sort the records that ship "Today", (or whatever other choice they made). I tried to do an "if" in the scriping window to accomplish this, but it's not working as I'd hoped. Am I going in the right direction, or am I missing an easy solution??? Thanks! Mark
February 2, 200619 yr You would need a global field that has the pull down menu on it. I called it gDateChoice. Then in your script, you can script something like this. If [ Jobs::gDateChoice = "Today" ] Enter Find Mode [] Set Field [ Jobs::JobDateField; Get ( CurrentDate ) ] Else If [ Jobs::gDateChoice = "Tommorow" ] Enter Find Mode [] Set Field [ Jobs::JobDateField; Get ( CurrentDate ) +1 ] Else If [ Jobs::gDateChoice = "2 Days" ] Enter Find Mode [] Set Field [ Jobs::JobDateField; Get ( CurrentDate ) +3 ] Else If [ Jobs::gDateChoice = "3 Days"] Enter Find Mode [] Set Field [ Jobs::JobDateField; Get ( CurrentDate ) +3 ] End If Perform Find []
Create an account or sign in to comment