Disappearing Listbox items...

K

Kevin

I'm using an ActiveX Listbox control in my Windows Forms program. I
can load the listbox and have it work fine on one of my forms. But
when I add the line:

Me.MDIParent = frmMain

the form appears with the items invisible. The scrollbar shows that
the items are in the listbox--I just can't see any of them.

If I comment out the above line, the items appear normally.

Has anyone else experienced this bug?
 
C

Cor Ligthert [MVP]

Kevin,

I think that few people can trace this this problem.

In my idea is normal code to create a mdichild from a mdiform by

dim mychild as new whateverform
mychild.MDIParent = me

Cor
 
K

Kevin

Because I need to be able to change the background color of each
individual item.

I tried using the Listview control and I get the same problem only
this time it doesn't matter if the form is a child form.

The scrollbar shows the items are there, they're just not visible (see
attached picture).
 
K

Kevin

....I meant also that I need checkboxes. I'd like to use the
CheckedListbox control, but I need to be able to change the background
color of each item. I know I can do that with an "owner drawn"
listbox, but the checkedlistbox doesn't support this.
 

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