Disabling form button after record change

Hello1

Registered User.
Local time
Today, 21:33
Joined
May 17, 2015
Messages
271
I have a main form with a button which is disabled by default.
In the main form I have a subForm with a combobox which on AfterUpdate event enables that button. However, when I change the record, so when I go to next, previous or either a new record I want the button to be disabled again.

I do know to set the button to be disabled again on form open, but I cant figure out a way on record change.

Thanks
 
The forms current event happens whenever you move to a record. So I think you want to disable after in the current event.
 
Hmm Im pretty sure I already tried that but it didn't work. I will try again.
 
Code:
[B]Private Sub Form_Current()
  Me.YourButtonName.Enabled = False
End Sub
[/B]
Linq ;0)>
 
For some reason it doesn't work with the on current event, it still stays enabled.
@missinglinq sorry but can you explain me "Linq ;0)>"
Tnx
 
Please provide real code that you are using.
 
It works, I had another control with a similar name so I used it instead the button. Thanks
 
Last edited:

Users who are viewing this thread

Back
Top Bottom