Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations biv343 on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Wildcards making form objects visible

Status
Not open for further replies.

brownlb

Technical User
Feb 4, 2002
2
US
I need to make a few captions and text boxes visible only when there is a *E* in the "Circuit ID" field.

Here's what I've got.

Private Sub Date_Order_Sent_Enter()
If [Circuit ID] = *E* Then <<<<It doesn't like this line
[ISP Vendor].Visible = True
Combo155.Visible = True
Combo157.Visible = True
Label99.Visible = True
Label156.Visible = True
Label158.Visible = True
End If
End Sub

It works great if I hard code a valid Circuit ID where the *E* is. What's the right way to do a wildcard in VBA? I know it's not *. I've tried [E] as well, and it still doesn't work.
 
Hi ,

Try ..

Code:
If [Circuit ID]
Code:
Like &quot;*E*&quot;
Code:
 Then

Enjoy,
Tony
 
Thanks Tony!

That's exactly what I needed. So simple, but I never would have figured it out!

Blair
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top