Home

Tuesday, January 6, 2015

set the focus on specific control when form is open

To set the focus on specific control when form is open, you need to override the firstField() method of the form and set your desired control after super() call.

public void firstField(int _flags=1)
{
    ;
    super(_flags);
    desiredControlName.setFocus();
}

public void firstField(int _flags=1)
{
    super(_flags);

    A_TableTest_A_LastName.setFocus();
   info(strFmt("%1", A_TableTest_A_LastName.valueStr()));

}

No comments:

Post a Comment