I have a main form with subform. A combo on the mainform is linked to the subform. Nothing complicated there. That works fine.
Also on the mainform is a text box. The contents of the text box are changed using the 'on change' event from the combo. This process only works when the subform returns records. When no records are returned an error is generated that states
'you can't reference a property or method for a control unless the control has the focus'
This occurs despite having explicitly given the focus to the textbox (in code) prior to trying to change its text.
I think the problem lies with the fact that the form expects to give focus to the subform but cannot because no records are returned, or something like that.
Please help!!!
Also on the mainform is a text box. The contents of the text box are changed using the 'on change' event from the combo. This process only works when the subform returns records. When no records are returned an error is generated that states
'you can't reference a property or method for a control unless the control has the focus'
This occurs despite having explicitly given the focus to the textbox (in code) prior to trying to change its text.
I think the problem lies with the fact that the form expects to give focus to the subform but cannot because no records are returned, or something like that.
Please help!!!