How to add a multi line list box?

M

MeAgin

Hi all,



I have a list box control derived from MS Forms 2.0 library in my VB.NET
2005 project. I want to add 2 columns of data for this and needs to show
only the 1st row. How this can be done?
It seems there is a limit no of methods and properties available.
The second column will store a value to reference the data shown. (The
Int_Key)

Thanks
Nadee
 
H

Herfried K. Wagner [MVP]

MeAgin said:
I have a list box control derived from MS Forms 2.0 library in my VB.NET
2005 project.

Bad idea. Note that the control is not redistributable and requires Office
to be installed.

Why not use 'System.Windows.Forms.ListBox', which has 'DataSource',
'DisplayMember', and 'ValueMember' properties.
 
M

MeAgin

Hi,

Thanks for the reply.

Yes in my case always office will be installed. I'm using this in an outlook
com add-in.
I have a list box in a outlook form and it cant be casted to a
System.Windows.forms.Listbox.
Therfore I have to cast it to a MS Forms 2.0 library.forms.ListBox. I want o
add some data to this list box.
I can add data using the AddMember() but when a value is selected I want use
the Int_Key to refer it back to the main data source.

Nadee
 

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