Why does this script end in wrong field?
I have this script set up to trigger when exiting a global field set up for searching the database.
If (not isempty (contacts: gsearchall))
- Set error capture (on)
- Enter find mode
- set field (contacts::search all; contacts::gsearchall)
- Perform find
- If (get (foundcount) > 0))
- clear (select; contacts::gsearchall))
- go to layout (list view (contacts))
- Show custom dialog
- End if
clear (select; contacts::gsearchall)
go to field (contacts::gsearchall)
It works fine except when no results are found and I click okay when exiting the custom message it clears the field but moves the cursor down to the next field. I don't know why. Why?
Thanks for any and all help.