Click here to Skip to main content
16,016,391 members
Home / Discussions / Visual Basic
   

Visual Basic

 
AnswerRe: Help Me to creat SQL Server Report ising SSRS 2005 Pin
Mekong River16-Jun-06 4:11
Mekong River16-Jun-06 4:11 
Questionnode diagram Pin
pavlaras1015-Jun-06 20:56
pavlaras1015-Jun-06 20:56 
Questionvb.net 1.1 Pin
constantinejones15-Jun-06 19:39
constantinejones15-Jun-06 19:39 
AnswerRe: vb.net 1.1 Pin
Dave Kreskowiak16-Jun-06 1:39
mveDave Kreskowiak16-Jun-06 1:39 
AnswerRe: vb.net 1.1 Pin
Mekong River16-Jun-06 4:07
Mekong River16-Jun-06 4:07 
QuestionChaning The Browser Settings using a VB Activex Controls Pin
srinivasaRaoS15-Jun-06 18:59
srinivasaRaoS15-Jun-06 18:59 
AnswerRe: Chaning The Browser Settings using a VB Activex Controls Pin
Mekong River16-Jun-06 4:03
Mekong River16-Jun-06 4:03 
QuestionLoad multiple open file name in the list box Pin
Mekong River15-Jun-06 18:35
Mekong River15-Jun-06 18:35 
Hi, I have a question relate to open file dialog and list box in vb.net. Currently I have:

One text box
One browse button
and one list box

My purpuse is:
1. Click on browse button and multiple select the file that I need.
2. When user click open, return the file path to text and display all file name that i multiple select in list box.

I could do the step 1 but I could not do the step 2. Here is my code that didn't work as my expectation:

Private Sub btnBrowse_Click(ByVal sender As System.Object, _
ByVal e As System.EventArgs) Handles btnBrowse.Click

    Try
        With ofdOpenData
            ' Start to open file in My document folder by default.
            .InitialDirectory = System.Environment.GetFolderPath( _
            Environment.SpecialFolder.Personal)
            .Filter = "All Files (*.*)|*.*|Microsoft Access Database " & _
            "(*.mdb)|*.mdb"
            .DefaultExt = "mdb"
            .ShowDialog()
            Dim dlgResult As DialogResult
            If dlgResult <> DialogResult.Cancel Then
                ' Clear the list box to get the new itmes.
                lstFilesList.Items.Clear()
                txtBrowse.Text = .FileName
                lstFilesList.Items.AddRange(.FileNames)
            End If
        End With
    Catch ex As Exception
        MsgBox(Err.Description.ToString, , "Error")
    End Try

End Sub


What i get is all file name with its folder path display in the list box and the text box display the last select file name and its path.

Can anyone help me?
QuestionWord Automation using VB Net Pin
aakar15-Jun-06 15:22
aakar15-Jun-06 15:22 
AnswerRe: Word Automation using VB Net Pin
Mekong River16-Jun-06 4:00
Mekong River16-Jun-06 4:00 
Questionhow to create the MDB programmatically Pin
changeez15-Jun-06 11:53
changeez15-Jun-06 11:53 
AnswerRe: how to create the MDB programmatically Pin
Mekong River15-Jun-06 15:25
Mekong River15-Jun-06 15:25 
GeneralRe: how to create the MDB programmatically Pin
changeez16-Jun-06 1:04
changeez16-Jun-06 1:04 
GeneralRe: how to create the MDB programmatically Pin
Mekong River16-Jun-06 3:47
Mekong River16-Jun-06 3:47 
QuestionFrom Where Can I get VB.NET e-Book? Pin
Syed Ali Raza15-Jun-06 11:12
Syed Ali Raza15-Jun-06 11:12 
AnswerRe: From Where Can I get VB.NET e-Book? Pin
Mekong River15-Jun-06 15:31
Mekong River15-Jun-06 15:31 
GeneralRe: From Where Can I get VB.NET e-Book? Pin
Kevin McFarlane16-Jun-06 0:10
Kevin McFarlane16-Jun-06 0:10 
GeneralRe: From Where Can I get VB.NET e-Book? Pin
Mekong River16-Jun-06 0:18
Mekong River16-Jun-06 0:18 
QuestionDatagrid Column DataType convert Pin
WayneXu15-Jun-06 9:50
WayneXu15-Jun-06 9:50 
Questionset FolderBrowserDialog root folder to a remote machine Pin
isgrom15-Jun-06 9:01
isgrom15-Jun-06 9:01 
AnswerRe: set FolderBrowserDialog root folder to a remote machine Pin
Mekong River16-Jun-06 3:54
Mekong River16-Jun-06 3:54 
GeneralRe: set FolderBrowserDialog root folder to a remote machine Pin
isgrom16-Jun-06 4:44
isgrom16-Jun-06 4:44 
GeneralRe: set FolderBrowserDialog root folder to a remote machine Pin
Mekong River16-Jun-06 5:03
Mekong River16-Jun-06 5:03 
QuestionSHAutoComplete Pin
MohammadAmiry15-Jun-06 8:03
MohammadAmiry15-Jun-06 8:03 
AnswerRe: SHAutoComplete Pin
Mekong River16-Jun-06 3:55
Mekong River16-Jun-06 3:55 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.