jokers6 0 Newbie Poster

Hey guys i have this program and i want you to tell me what is wrong cuz i can't figure it out !!
This is what i have to do: (the code follows)
When the form is loaded, read the records in P3S3 Data File For Import.txt to a listbox (attached). Note
the following:
o Use a StreamReader class to perform the data file reading (importing).
o Be sure you do not import the first two records in the data file into the listbox. - (don't know how to)
o Be sure you do not import records that have no entries in the data file into the listbox (i.e.
each imported record must have at least one character in its string). - ( ? meh )
o Size the listbox to show 10 records. - ok i knw this !!
 Include a "Letter To Filter" DropDownList combo box that contains all letters in the alphabet,
each upper-cased. Provide a caption to the combo box of "Letter To Filter" and set its default
letter (i.e. Text property) to be "C" when the form loads.
 Include two buttons on the form. The first button should be captioned "Export" and the second
button should be captioned "Exit".
 For the "Export" button, Note the following:
o Provide a FolderBrowserDialog common dialog box to allow the user where the file should
be exported to. Then, export the records in the listbox to a data file named P3S3 Data File
For Export.txt. Be sure the data file is in the location specified by the user via their
common dialog box choice.
o Use a StreamWriter class to perform the data file writing (exporting).
o If the data file already exists, exporting to it should overwrite any existing contents in the file.
o Export records whose starting character matches the letter specified by the user in the
"Filtering Export Letter" combo box. For example, if the user selects the letter "A" (no
quotes) from the combo box, write only records beginning with the letter "A" (i.e. "Algeria",
"Argentina", etc.) to the data file. If no records in the listbox begin with the combo box
filtering letter, write "RECORD CRITERIA NO MATCHES" to the data file. Maintain a
total of how many records are exported.
 For the "Exit" button, note the following:
o Display a message box of the filtering export letter used, the number of records that were
exported, and the folder location where the exported data file resides. If not export was
attempted, display a suitable message in the message box.
o Then, close the form.

Here is the code:

Imports System.IO

' Program: Project 3 Section 3
' Programmer: Kristin Augustine
' Date: 12/16/2009
' Description: Retrieve the information stored in a data file and display it on the screen.
'           Uses a StreamReader.
' Declare a module-level variable.

Public Class frmP3S3DataFileTasks
    ' Declare a module-level variable.
    Private LocationStreamReader As StreamReader

    Private Sub DisplayForm_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
        Dim strImportFile As New StreamReader("P3S3 Data File For Import.txt")
        Dim strNames As String

        ' Process the stream's contents.
        strImportFile.ReadLine()
        strImportFile.ReadLine()
        Do While strImportFile.Peek <> -1
            strNames = strImportFile.ReadLine()
            If strNames.ToString.Length >= 1 Then
                lstCDCLocations.Items.Add(strNames)
            End If
        Loop

        ' Clean-up code.
        strImportFile.Close()
        MessageBox.Show("Import completed.")

        cboLetterToFilter.Text = "C"
    End Sub


    Private Sub btnExit_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnExit.Click
        Dim intconfirmExit As Integer
        ' Close the form.
        intconfirmExit = MessageBox.Show("Do you really want to exit?", _
                                          "Confirmation...", _
                                          MessageBoxButtons.YesNo, _
                                          MessageBoxIcon.Information, _
                                          MessageBoxDefaultButton.Button2)
        ' Debug.WriteLine("Value of intConfirmExit is: ' & intConfirmExit)
        If intconfirmExit = vbYes Then

        End If
        Me.Close()

        If Not LocationStreamReader Is Nothing Then
            ' Close the file, only if it is open.
            LocationStreamReader.Close()
        End If
        Me.Close()
    End Sub

    Private Sub btnExport_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnExport.Click
        ' Export the files

        Dim swrExportFile As New StreamWriter("P3S3 Data File For Export.txt")
        Dim intLoopCtr As Integer = 0
        Dim strSelectedPath As String
        Dim intLoopCounter As Integer
        Dim strStartWith As String

        dlgFolder.ShowDialog()
        strSelectedPath = dlgFolder.SelectedPath

        For intLoopCounter = 0 To lstCDCLocations.Items.Count - 1
            lstCDCLocations.Items(intLoopCounter).ToString()
        Next


        ' Clean-up code.
        swrExportFile.Close()
        MessageBox.Show("Export completed.")
    End Sub
End Class

i have attached two files .... one is the .txt file needed for the program and other is a picture of the form !! lol its a .doc
i knw its not all right ... what changes do i have to make ? please help :) thank you.