复选框仅显示标签上的一项

时间:2018-07-15 14:30:13

标签: vb.net

我正在尝试显示我已检入数据的所有项目,但仅显示一个项目enter image description here

    Private Sub Form9_Shown(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Shown
    'Load data
    Dim sReader As New System.IO.StreamReader(Form1.pathAppointments & selectedAppointment & "\appointmentData.txt")
    Dim lbData As New ListBox
    While sReader.Peek <> -1
        lbData.Items.Add(sReader.ReadLine)
    End While
    sReader.Close()

    'Visualise data
    lblPatientName.Text = lbData.Items(1)
    lblCaseType.Text = lbData.Items(0)
    lblDate.Text = lbData.Items(2)
    lblMedication.Text = lbData.Items(5)
    lblAppointmentFor.Text = lbData.Items(3)
    lblLocation.Text = lbData.Items(4)
    lblTor.Text = lbData.Items(6)
    lbllab.Text = lbData.Items(7)




End Sub

0 个答案:

没有答案