Hi,
I have a form with several fields.
The code behind these fields is exactly the same.
example: see attachment
I would like to write one sub and give the fieldnames as parameters to he sub
see attachment
Hi,
I have a form with several fields.
The code behind these fields is exactly the same.
example: see attachment
I would like to write one sub and give the fieldnames as parameters to he sub
see attachment
Not on a computer right now but try
Forms(strForm).Controls(strTextbox)
Hi Ann!
Give a try to the code below:
Cheers,Code:Private Sub cbxAfwerk3_Click() CheckOnOff Me.Afwerk3, Me.cbxAfwerk3 End sub Sub CheckOnOff(ctrCheck As CheckBox, ctrImage As Image) If ctrCheck Then ctrImage.Picture = "" ctrCheck = False Else ctrImage.Picture = strPath & "vink.jpg" ctrCheck = True End If End Sub
John