Combobox resetting to default value

  • I have two UserForms and two scenarios.


    Scenario #1: The UserForm1 has combobox' that's supposed to be filled up beforehand before UserForm2 is shown, the problem occurs whenever I unload UserForm2, all the combobox' resets to their default values, why?



    Scenario #2: When I click outside the UserForm1, for example the desktop, then clicks back to UserForm1, the same problems occurs, combobox' resets to their default values, why?

  • Re: Combobox resetting to default value


    that's the thing, I have not declared anything to reset those combobox'
    this is the syntax on the UserForm2


  • Re: Combobox resetting to default value


    Quote

    When I click outside the UserForm1


    Maybe there's code in the userform Activate event? I think a copy of the workbook is needed.

  • Re: Combobox resetting to default value


    YES!! that exactly that, I knew something was wrong, I had the code for filling up the boxes in a UserForm_Activate rather than UserForm_Initialize. Thank you!!

Participate now!

Don’t have an account yet? Register yourself now and be a part of our community!