CheckedListBox Losing Checks

B

Brian Mitchell

I have no idea what I am doing wrong, but I have a CheckedListBox (Bound to
an IList) on a TabControl and everytime I switch tabs I lose my checks. Is
there something I'm missing? If I look at the properties of my IList class I
can still see the properties have not changed (which means the items in the
box should still be chekced) it's just like for some reason the ListBox
doesn't keep the checks.

Thanks for the help!!
 
G

Gerald Hernandez

heh, this seems to be noticed in waves. seen this a few times in the last
couple days.
I ran into this a long time ago.
It appears that the TabControl is somehow preventing or causing the
CheckedListBox to not render correctly. The TabControl sometimes also seems
to affect other controls as well, but the CheckedListBox seems to be the
most affected.
I don't have a simple fix, and so far I have not come across a good
explanation or fix.
In my case, I really needed special behaviour, so I extended the
CheckedListBox control myself. So far I have not seen the same problem with
the version I'm using.

Maybe someone else has come across a solution by now?

Gerald
 
G

Gerald Hernandez

Ah, forgot about that article.
However, contrary to their comment about it only affecting Data Bound
CheckedListBoxes, in every situation it has happened to me, there was no
data binding involved.

Gerald
 
B

Brian Mitchell

Thanks for the reply, what I ended up doing is just iterating through my
datasource and manually populating the list with the objects. This seems to
work....at least for now.
 
C

Cor Ligthert

Brian,

I am not sure of this, however I thought that the Ilist binding was a one
way binding, only setting of the control and not the other way.

Cor
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top