ListBox_Click() Event

mikeymay

Well-known Member
Joined
Jan 17, 2006
Messages
1,645
Office Version
  1. 365
Platform
  1. Windows
I am trying to implement a detection of a listbox item being clicked, either to select or unselect.

In previous projects I have used the _Click() event which has work exactly as I have needed it but this doesn't seem to work when implementing in this new project.

I have reviewed the project in which this was implemented and in that project the code executes as required, an item in the ListBox is clicked and the event fires.

From what I can see, it is suggested that the _Change event is used but this fires when the ListBox is being changed (either being populated with the RowSource and/or items being removed when I use a control to move the selected items to another ListBox) which I don't need to happen. I appreciate I can add some code to exit the event when it isn't needed but the _Click event worked perfectly well before......

Has there been a change in the VBE in the last 18 months to stop the _Click event working?


TIA
 

Excel Facts

Remove leading & trailing spaces
Save as CSV to remove all leading and trailing spaces. It is faster than using TRIM().
After a bit more digging it seems that is a ListBox's MultiSelect option is set to Multi, the _Click evet doesn't trigger.......how that makes sense I don't know.

Time for more unecessary code to be added......
 
Upvote 0
Solution

Forum statistics

Threads
1,224,820
Messages
6,181,162
Members
453,021
Latest member
Justyna P

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top