Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
DiscussionsAccessExcelInfoPathOutlookPowerPointPublisherWord
DirectoryUser Groups
Related Topics
Outlook ExpressInternet ExplorerWindowsMS Server ProductsMore Topics ...

MS Office Forum / Excel / Programming / December 2007

Tip: Looking for answers? Try searching our database.

if not isempty combobox does not work ?

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Pierre - 19 Dec 2007 20:11 GMT
Hi,

I have the following piece of code for two comboboxes in a userform;

If Not IsEmpty(zoekwg.Value) Then
   'This Combobox was selected
   klantkeuze = zoekwg.Value
   Set klantmatrix =
Worksheets("datadga").Range("B2:b500").Find(klantkeuze)
ElseIf Not IsEmpty(zoekdga.Value) Then
   'Combobox2 was selected
   klantkeuze = zoekdga.Value
   Set klantmatrix =
Worksheets("datadga").Range("B2:b500").Find(klantkeuze)
End If

If box1 is empty then it should look if there is something in box2
However, allthough I put nothing in box1, it still sees it as NOT empty !

The code for filling the boxes is;

zoekdga.RowSource = "B2:B1000"
zoekwg.RowSource = "B1:FX1000"

I would like to have the first piece of code check if the user has input
something in box1. If the user didn't it should do the same in box2.

Any suggestions?
Thanks,
Pierre
Joel - 19 Dec 2007 20:48 GMT
Try

If zoekwg.Value <> "" Then

> Hi,
>
[quoted text clipped - 26 lines]
> Thanks,
> Pierre
Pierre - 20 Dec 2007 13:14 GMT
Hi Joel,

djee....that was simple.
Sorry for making it so troublesome.
Thanks for your help,
Pierre

> Try
>
[quoted text clipped - 30 lines]
>> Thanks,
>> Pierre
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.