PDA

View Full Version : Worksheet change clears selection(s) on MultiSelect type listbox.



morsoe
02-28-2014, 01:39 AM
I have several activeX type listbox objects placed in a worksheet (not a userform). One of these has been set as MultiSelect.

The problem is that any change to any sheet on any workbook within the Excel instance has the annoying and inexplicable effect to clear all selections in the multi select listbox.
There are no event codes placed to any of the objects incl worksheet project.

I can probably smoothly work around this by placing the controls in a userform or by reading the selections to an array in VBA before placing using them in my worksheet, however, I would really like to learn how to avoid this.

:hi:Can anyone help?

snb
02-28-2014, 04:53 AM
Can you post a sample file ?

morsoe
02-28-2014, 05:23 AM
Can you post a sample file ?

Hello my friend. Thanks for looking, upload now in place. Please dont care to much about the current VBA code, it's under construction.

Thanks

snb
02-28-2014, 08:21 AM
As long as you want to keep the options selected you will have to use :


Sub M_snb()
Application.Calculation = xlCalculationManual
End Sub

morsoe
03-03-2014, 12:45 AM
Thanks. Yet a workaround (… and not a very good one seeing that worksheet eventually will be calculated). Do you have any idea why the worksheet list box control has this irrational behavior?