Multiselect issue + array ....

Hi everyone!

I am not sure which control to use to display all selected files after multiselecting more then 1 file from my open file dialog box.

Whats the best control to use for this keeping in mind that I will have to be able to view all files selected (which possible could be a maximum of 100).

How would i get the values of all the filenames to show up in the control.

So far I can manage working with one file but i am not sure how to handle this multiselect filenames and what the most common way of dealing with this is ... i want users to be able to see all the selected files after selecting them from the Open File Dialog.

Thanks for your help!

Rob


I am using following code:

[CODE]

Private Sub btnXMLBrowse_Click_1(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnXMLBrowse.Click
Dim aFilePath As Array
With ofd
.CheckFileExists = True
.CheckPathExists = True
.Multiselect = True
.ShowHelp = False
.ShowReadOnly = False
.Title = "My Open File Dialog"
.Filter = "XML files only (*.xml)|*.xml|All Files (*.*)|*.*"
.FilterIndex = 0
.InitialDirectory = "R:\ACCESSDOC\DAFNE"
'Environment.GetFolderPath(Environment.SpecialFolder.MyDocuments)
If .ShowDialog = Windows.Forms.DialogResult.OK Then

aFilePath = ofd.FileNames
For Each s As String In ofd.FileNames

Msgbox ("test")

Next

txtXMLPath.Text = .FileName.ToString()
If txtRTFPath.Text.Length = 0 Then
txtRTFPath.Text = Path.Combine("C:\Test\Files", Path.ChangeExtension(Path.GetFileName(txtXMLPath.Text), ".txt"))
End If
End If
End With
End Sub

[/CODE]
[2080 byte] By [dev121] at [2008-1-9]