S
Shawn
I know that I can use DisplayMember and ValueMember when using a DataSource
on the ListBox, but is it possible to use the same technique when using
ListBox.Items.Add method? In my application I use a OpenFileDialog to let
the user select filenames into the ListBox. The problem is that I don't
wish to show the path + filename in the ListBox, only the filename. But I
need the full path to know where the file is so I can't just chop it off. I
could use DataSource with DisplayMember and ValueMember, but then I won't be
able to remove any of the items in the ListBox, and I have to be able to do
that...
Any help is greatly appreciated.
Shawn
on the ListBox, but is it possible to use the same technique when using
ListBox.Items.Add method? In my application I use a OpenFileDialog to let
the user select filenames into the ListBox. The problem is that I don't
wish to show the path + filename in the ListBox, only the filename. But I
need the full path to know where the file is so I can't just chop it off. I
could use DataSource with DisplayMember and ValueMember, but then I won't be
able to remove any of the items in the ListBox, and I have to be able to do
that...
Any help is greatly appreciated.
Shawn