Hi,
I am using MS Access 2000.
I have created a form from only ONE table.
The form contains one drop down field, which can have only two values; A or B. This drop down is also from the same table.
If I select A, I can enter data in fields G, H, and I.
If I select B, I can enter data in fields C, D, and E.
While entering data for G, H, and I, if I switch from A to B, I want the values of the fields G, H, and I reset to 0.
Similarly if I switch to B to A, while I am entering data in C, D, and E, the values of the fields C, D, and E should reset to 0.
I have tried to use the "Change", "Exit" and "LostFocus" functions of the field that holds the A and B information, and tried to set the value of the fields C,D,E or G,H,I to 0, but I get the following error:
"You can't reference a property or method for a control unless the control has the focus".
If thats the case I have to give focus to each field before I set its value to 0, is this the only way to proceed?
All the help is welcome and appreciated.
Thanks,
Indiana
I am using MS Access 2000.
I have created a form from only ONE table.
The form contains one drop down field, which can have only two values; A or B. This drop down is also from the same table.
If I select A, I can enter data in fields G, H, and I.
If I select B, I can enter data in fields C, D, and E.
While entering data for G, H, and I, if I switch from A to B, I want the values of the fields G, H, and I reset to 0.
Similarly if I switch to B to A, while I am entering data in C, D, and E, the values of the fields C, D, and E should reset to 0.
I have tried to use the "Change", "Exit" and "LostFocus" functions of the field that holds the A and B information, and tried to set the value of the fields C,D,E or G,H,I to 0, but I get the following error:
"You can't reference a property or method for a control unless the control has the focus".
If thats the case I have to give focus to each field before I set its value to 0, is this the only way to proceed?
All the help is welcome and appreciated.
Thanks,
Indiana