KeyPress event handler

Mkontwg

Member
Hi team

I want your help, i have an event handler txtUserName_KeyPress. But i want to add few logic. that is if a user press enter to the next field. Meaning they must use enter instead of tab. Can anyone show me default example, please thanks.

DEFINE VARIABLE txtUsername AS CHARACTER NO-UNDO.

???
 

Cringer

ProgressTalk.com Moderator
Staff member
Horrible idea to force users to comply with what you think is right, but
ON "TAB" OF <field> DO:
RETURN NO-APPLY.
END.
Something along those lines should do it.
 

TomBascom

Curmudgeon
It depends greatly on what you are doing. Perhaps if you showed slightly more code than a variable definition we could provide better insight.
 

Mkontwg

Member
Horrible idea to force users to comply with what you think is right, but
ON "TAB" OF <field> DO:
RETURN NO-APPLY.
END.
Something along those lines should do it.
What i wanted to achieve, was the following below from my event handler.

txtUserName_keyDown()
IF e:KeyCode:Equals(System.Windows.Forms.Keys:Enter) THEN DO:
txtPassWord:Focus().
END.
e:Handler = TRUE.
END METHOD.
 

Mkontwg

Member
Hi Guys

Has anyone ever worked with combo-box inside the grid? meaning by creating it via method from the Appserver, then when i click the field from the grid(temp-table) assigned or bind i can pull it with its value and data. I need some examples please
 
Top