Hi folks, I'm having a bit of an issue with a userform and was hoping for some advice.
I have a userform with lots of controls on it, one of which is a list box containing all the fault numbers in the spreadsheet. When the user selects a fault number from this list, all the other controls populate with data relating to that fault. This has all been working fine for some time. However, I recently added a new control (DNList in the code below) and that's what's causing me problems.
I added a listbox which shows software fixes associated with the selected fault and allowed the user to right-click or double-click the new list box in order to bring up more details. These details open in more userforms and all work fine. However, when closing either of the user forms opened from this new list box the main userform appears to be locked. None of the buttons work, the main list box doesn't respond, nothing. If I click in the new list box it seems to unlock everything and the user continues quite happily.
This is the code for right-clicking the new listbox (the double-click sub is almost identical)
After the "AddRemoveDN.Show", control should return to the Main form, but it doesn't.![]()
Please Login or Register to view this content.
I've tried to programmatically fix this by adding code after "AddRemoveDN.Show" to
Set the focus to DNList
Set the focus to FaultList
Set the focus to FaultList then back to DNList
Set the focus to DNList and the using Sendkeys to move Up/Down/Home/End
Changing the 2 userforms opened from the new listbox to both Modal and NonModal
Nothing seems to work.
Any help would be greatly appreciated.
Bookmarks