rickyoswaldiow
Programmer
Evening all. I am trying to acomplish somthing very simple but my program is falling over:
My error message is:
You can't reference a property or method of a control unless the control has the focus.
The form that these controls occupy should have focus, since the code is called up from another control on the same form and there is no reference to any other forms. I have also tried to .setfocus but this gives me the error:
Fundamental Microsoft Jet SQL for Access 2000 can't move the focus to the control txtCustomerID
Code:
With rsCustomers
If Not .EOF And Not .BOF Then
Me.txtCustomerID.Text = !CustomerID
Me.txtFirstName.Text = ![First Name]
Me.txtSurname.Text = ![Last Name]
Me.txtTelephone.Text = !Phone
Me.txtEmail.Text = !Email
End If
End With
My error message is:
You can't reference a property or method of a control unless the control has the focus.
The form that these controls occupy should have focus, since the code is called up from another control on the same form and there is no reference to any other forms. I have also tried to .setfocus but this gives me the error:
Fundamental Microsoft Jet SQL for Access 2000 can't move the focus to the control txtCustomerID