rudeboymcc
Registered User.
- Local time
- Today, 04:51
- Joined
- Sep 9, 2008
- Messages
- 69
Hi. I've got a form which is very similar apart from a few texts boxes, so I hide the relevant textboxes that I don't need dpending on the OpenArgs.
E.g.
I want to make a function like this:
But at the moment, If I call it with either of the two below in the Form Load event, it says "Object Required" and highlights the line (So it doesn't even get to the hideControl function)
This is really simple but sometimes it's the simpelst things that take longest.
E.g.
Code:
Me.cmbHB.Visible = True
Me.cmbHB.Height = 0
I want to make a function like this:
Code:
Private Function HideControl(ctr As Control)
ctr.Visible = False
ctr.Height = 0
End Function
Code:
HideControl(Me.cmbHB)
HideControl(Me.Controls("cmbHb"))
This is really simple but sometimes it's the simpelst things that take longest.