Unanswered: Show / Hide command button via combobox selection & displayed record
Im trying to show/hide a command button (cmd97) on a form. The form Default View is set to Single.
There is a combobox (combo107) on the form with a "Yes" / "No" option for the particular record being viewd. The combobox "yes" / "no" selection is stored to a table for that particular record.
There are also "Next" & "Previous" command buttons to move through the records on the form
If, on a particular record the combobox is "yes" then I want to show the command button.
If, on a particular record the combobox is "no" then I want to hide the command button.
I also want the command button (cmd97) to be shown or hidden when I move through records on the form via the "Next" & "Previous" buttons depending on wether the combobox was set to "Yes" or "No" for each record.
I have tried this code in the combobox after update, and the "Next" & "Previous" command button onclick events, but cannot get it to work, the button vanishes and doesnt re-appear -
If Combo104.Value = Yes Then
Command97.Visible = True
Command97.Visible = False
I need to know in which events I need to be placing the code