C
cmw
On the click event of one listbox (ListA), I call a routine that determines
which controls on the form should be available for editing. If a control
should not be available and contains data, the control is cleared then
locked. Works on everything but a second listbox (ListB) including a 3rd
listbox (ListC).
First, I select item 1 to return the list to the top most position and to
unselect
the selected item if any. Then, I set unselect it and lock it.
ListB.Selected(1) = True
ListB.Selected(1) = False
ListB.locked = true
--> Error Msg
If I don't perform the select, I can lock and unlock the control at will. It
will not allow me to move the focus to ListB or any other control.
I have a 3rd listbox (ListC) which I empty and lock. That works fine
Do while ListC.ListCount > 0
ListC.RemoveItem(ListC.Listcount -1)
loop
ListC.locked = true
Thanks for your help
which controls on the form should be available for editing. If a control
should not be available and contains data, the control is cleared then
locked. Works on everything but a second listbox (ListB) including a 3rd
listbox (ListC).
First, I select item 1 to return the list to the top most position and to
unselect
the selected item if any. Then, I set unselect it and lock it.
ListB.Selected(1) = True
ListB.Selected(1) = False
ListB.locked = true
--> Error Msg
If I don't perform the select, I can lock and unlock the control at will. It
will not allow me to move the focus to ListB or any other control.
I have a 3rd listbox (ListC) which I empty and lock. That works fine
Do while ListC.ListCount > 0
ListC.RemoveItem(ListC.Listcount -1)
loop
ListC.locked = true
Thanks for your help