Edit command executing Leave Field

Author: yashgupta636@gmail.com (yagupta636)

Hi, I have an issue with the edit command. I have used 'edit Litname' in my code (Uniface v9.6.04). In one of the scenario while executing the edit command, it is activating the 'Field Gets Focus' trigger(expected) but after this 'Leave Field' trigger calls itself. I am not sure what could be the possibility of this behavior. Can anybody help me in this. Thanks in advance. :)


  1. Hi yagupta636, my gotfeel is you could have misunderstood what edit statement means in Uniface. edit statement is aiming to show your component on screen and start an edit session. This edit session will end when your user is exiting from the component QUITting or ACCEPTing. Probably in your "Leave Field" trigger you would like to position your cursor back to a field...Am I guessing it right? You could do it with: $prompt = YourFieldNameHere Regards, Gianni

    Author: gianni (gianni.sandigliano@unifacesolutions.com)
  2. I'm with Gianni; The edit statement is typically done only once in the execute trigger; after having run some initial code, you're now 'handing over' the form to the user for editing. Edit statement followed by a fieldname also starts the editing, but then prompted to that specific fieldname. If later on you need to set the cursor to a specific field, $prompt is indeed the statement to use.

    Author: Arjen van Vliet (arjen.van.vliet@uniface.com)
  3. I don't think yagupta636 means he has an edit statement in the leave field trigger. That would cause a compilation error. Yagupta636, can you please explain in more detail what you are trying to do and what happens?   Theo Neeskens Solution Architect, Uniface BV

    Author: Theo Neeskens (tneeskens@itblockz.nl)