Results 1 to 3 of 3

Thread: [RESOLVED]Openfiledialog

  1. #1

    Thread Starter
    Addicted Member
    Join Date
    Jul 2005
    Location
    Chicago
    Posts
    202

    [RESOLVED]Openfiledialog

    I just took out a few lines and it worked fine.
    VB Code:
    1. On Error GoTo TheError
    2.         Dim AllText, LineOfText As String
    3.         ofdInserttrack.Title = "Add a Track to the Mediaplayer"
    4.         ofdInserttrack.Filter = "All Song Types(*.mpeg,*.avi,*.mp3,*.wav,*.wma,*.cda)|*.*|MPEG (*.MPEG)|*.MPEG|avi (*.avi)|*.avi|MP3 (*.mp3)|*.mp3|Wav(*.wav)|*.wav|WMA (*.wma)|*.wma|CD(*.cda)|*.cda"
    5.         If ofdInserttrack.ShowDialog = DialogResult.Cancel Then
    6.             Exit Sub
    7.         Else
    8.             playlist.Items.Clear()
    9.             playlistPath.Items.Remove(playlistPath.SelectedIndex)
    10.             playlistPath.Items.AddRange(ofdInserttrack.FileNames)
    11.             MP3.ListNoChar(playlist, playlistPath)
    12.             If playlist.Items.Count > 1 Then
    13.                 btnNext.Enabled = True
    14.                 mnuNext.Enabled = True
    15.                 btnPrevious.Enabled = True
    16.                 mnuPrevious.Enabled = True
    17.             End If
    18.         End If
    19.  
    20. TheError: MsgBox(Err.Description, , " Error")
    Last edited by wldrumstcs; Aug 6th, 2005 at 09:55 PM.
    A programmer is a person who fixes a problem you did not know you had in a way that you cannot understand.

  2. #2
    Fanatic Member
    Join Date
    May 2005
    Posts
    898

    Re: Openfiledialog

    VB Code:
    1. If openFileDialog1.ShowDialog() = DialogResult.OK Then
    2.    'do your stuff
    3. End If
    "so just keep in mind that fantasy is not the same as realtiy and make sure u remember that wii sports may be fun but u cant count on it as exercise ok cool bye" - HungarianHuman

  3. #3

    Thread Starter
    Addicted Member
    Join Date
    Jul 2005
    Location
    Chicago
    Posts
    202

    Re: Openfiledialog

    didnt mean to press reply
    A programmer is a person who fixes a problem you did not know you had in a way that you cannot understand.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width