HI All,
THE SETUP
I have a multicolumn list box which is populated with selected non-sequential columns from an excel worksheet. The worksheet is passed to the function(register), row is not currently used.
Output Jobs is the name of the list box on the user form.
I use the code below to populate the list box when the user form is first loaded. No problems at all.
THE PROBLEM
After an entry is entered(a job) by the user it is entered into the worksheet (register), I then call this code again to update the list box, without closing the user form. The register sheet is closed after entry of the new job into the file adn opened again to update the list box.
The list box values update but the text is left completely blank, i.e I can select the updated values there is just no text for them.
If I remove the OutputJobs.clear statement and remove each item individually then add the new items, the old text appears in the list box, but the new selection value is there when you click, so everything is shifted by one, and the new text value appears at the bottom of the list.
The only way I can update the listbox correctly is to close the userform and reload it which I do not want to do.
THE CODE
All I want is the list box to show the correct text when the values are updated, can anyone help I have searched hundreds of threads but found nothing that would work.
Thanks for in advance for your time and help,
Shane
Bookmarks