+ Reply to Thread
Results 1 to 5 of 5

Error 1004 - hitting a key in a dropdown list of a userform

  1. #1
    Registered User
    Join Date
    01-17-2012
    Location
    Hungary
    MS-Off Ver
    Excel 2007
    Posts
    5

    Error 1004 - hitting a key in a dropdown list of a userform

    Hi All,

    I have a workbook with a quite complex userform, where the contents of the drop down lists depends on one another. And when the cursor is in a combo box and I hit a key (expecting to see the first item of the list beginning with that caracter) it causes run-time error 1004. If I double click in the box first selecting the content and then I hit the key it works as expected.
    Unfortunatly I cannot attache the workbook as it's too huge and highly confidential, but I hope that my problem is general enough to get an answer anyway. I've tried to search for error 1004 but haven't found any relevant solutions.

    Thanks for your help in anticipation!

  2. #2
    Registered User
    Join Date
    01-17-2012
    Location
    Hungary
    MS-Off Ver
    Excel 2007
    Posts
    5

    Re: Error 1004 - hitting a key in a dropdown list of a userform

    Please help!

    If my problem is too obvious at least give me hints on how to search for a solution on the net. If you think that's just can't be resolved, beacuese that's how the combobox in excel should work, tell so, and I can give up searching!

    Thanks!

  3. #3
    Forum Expert OnErrorGoto0's Avatar
    Join Date
    12-30-2011
    Location
    I DO NOT POST HERE ANYMORE
    MS-Off Ver
    I DO NOT POST HERE ANYMORE
    Posts
    1,655

    Re: Error 1004 - hitting a key in a dropdown list of a userform

    I think it is precisely because your problem is too vague that we cannot diagnose it. 1004 is a non-specific error number (it basically says something has gone wrong) and all you have told us is that your form is complex with a lot of interrelationships. I would imagine those relationships are the issue but without knowing anything about your form it is impossible to be more specific.
    Good luck.

  4. #4
    Registered User
    Join Date
    01-17-2012
    Location
    Hungary
    MS-Off Ver
    Excel 2007
    Posts
    5

    Re: Error 1004 - hitting a key in a dropdown list of a userform

    Thanks. Trying to be more specific.
    The combo box feeds a lookup function. What I don't understand is why VBA tries to move on to the lookup function when I start to type a value in the combo box (if the cursor is active within the combo box)? However I can start typing the values after double cliking in the combo box, and excel promts me the items of the list that matches the first characters I've typed in.
    I hope it makes sense....

  5. #5
    Forum Guru Kyle123's Avatar
    Join Date
    03-10-2010
    Location
    Leeds
    MS-Off Ver
    365 Win 11
    Posts
    7,238

    Re: Error 1004 - hitting a key in a dropdown list of a userform

    It would depend on where your code is placed, the change event fires as soon as you start typing

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1