AnsweredAssumed Answered

FMP10 script trigger bug?

Question asked by sschwartz_1 on Jan 26, 2009
Latest reply on Jan 27, 2009 by sschwartz_1

Title

FMP10 script trigger bug?

Post

As a test of the new script trigger feature, I created a simple script that I attached to a field formatted as a drop-down list. (The field's name is Type.) Depending on what the user chooses from the list, one of two possible Go To Field steps is executed.

 

Here's the script:

 

If [Checkbook::Type = "Check"]
   Go to Field [Checkbook::Number]
Else
   Go to Field [Checkbook:: Date]
End If 

 

Unfortunately, it doesn't work. No matter what the user chooses from the drop-down list, the next field in the tab order is automatically selected. (It happens to be the Number field.) When I test the script in the Script Debugger, it works flawlessly -- just not when I attempt to run it normally. I get the same result when I test this using OnObjectModify, OnObjectSave, or OnObjectExit.

 

After messing with this for an hour and getting nowhere, I simply started "trying stuff." For some reason that I can't fathom, adding a Halt Script as the final step makes the trigger work correctly. Is this a bug related to using a script trigger in conjunction with Go to Field? (If I replace the Go to Field steps with something else, such as Speak or Beep steps, the trigger works without having to add the Halt Script step.) Or is this just something undocumented that I tripped over?

 

Steve 

Outcomes