edmoor
Inventaris
- Lid geworden
- 8 sep 2000
- Berichten
- 39.744
- Besturingssysteem
- Windows XP, 7, 10, 11-23H2
- Office versie
- Office 365
Probeer dit eens:
Code:
Private Sub Form_Load()
ipos = -1
On Error Resume Next
Dim Bestand As Long
Dim lijn As String
Dim textAndValue() As String
List1.Clear
Bestand = FreeFile
Open App.Path & "\BLOPaper.txt" For Input As #Bestand
Do While Not EOF(Bestand)
Line Input #Bestand, lijn
If Len(lijn) Then
List1.AddItem Split(lijn, "*")(0)
teksten(aantalteksten) = lijn & "*"
aantalteksten = aantalteksten + 1
End If
Loop
Close #Bestand
End Sub
Private Sub List1_Click()
If List1.ListIndex >= 0 Then
Text1.Text = Split(teksten(List1.ListIndex), "*")(1)
If UBound(teksten) > 1 Then
Text2.Text = Split(teksten(List1.ListIndex), "*")(2)
End If
End If
End Sub