Skip to Content
avatar image
Former Member

Control affects form mode when not needed

My form has a combo box that is used to control the contents of a grid. The grid is reloaded when a refresh button is clicked based on the value in the combo box.

I have set 'AffectsFormMode="0" ' in the xml for the combo box and the refresh button.

Starting in "OK" mode when I initially change the value of the combo box the "OK" mode persists. Once I click refresh the grid refills with data and the mode remains "OK".

The next time I change the value in the combo box the mode changes to "Update" even though the combo box should not "affect the form mode".

It's annoying to have the form go into Update mode innapproriately. The only way out is to update the form.

Has anyone seen this problem? Is it a bug in the UIAPI or am I doing something wrong.

Thanks for any help.

Add comment
10|10000 characters needed characters exceeded

  • Follow
  • Get RSS Feed

2 Answers

  • Best Answer
    Sep 12, 2008 at 11:12 PM

    Hi Mel,

    There are actually 2 AffectsFormMode properties for a ComboBox. Why this is the case is a mystery but only one affects how the combo changes the form mode.

    If you use Screen Painter to create your form, then a combobox will look similar to the following:

    <item uid="MyCombo" type="113" AffectsFormMode="1" ...
    	<specific AffectsFormMode="1" TabOrder="0">
    			<action type="add"/>
    		<databind databound="0" ...

    Note that the AffectsFormMode property appears at the item node level and at the specific level. It is the specific level one that affects the form mode. This is different to the other control types which only have this property at the item level.

    Kind Regards,


    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Sep 15, 2008 at 02:55 PM


    Thanks for your suggestion. I have made sure that all the "AffectsFormMode" properties are set to 0 but the probelm still persists.

    When my form first loads everything works fine and the form stays in OK mode no matter how many times I change the combo box.

    When I populate the grid the form stays in OK mode. However, once I try to change the combo after populating the grid then the mode changes to Update.

    I did a further test to eliminate the combo box as a variable by creating a text box with "AffectsFormMode=0" and found it behaves the same. It does not affect the form mode when edited until after I populate the grid by clicking the refresh button.

    Once the grid is populated I can focus on the text box and the form remains in OK mode. This seems to eliminate changes to the grid controls as being the cause of the form mode changing. However, once I change one character in the text box then the form mode becomes Update, as it did with the combo box.

    Why? No control with "AffectsFormMode=1" has been changed.

    Thanks for any help.


    Add comment
    10|10000 characters needed characters exceeded