Checks username and Password from a text file using Filescripting.
Checks username and Password from a text file using Filescripting.
API Declarations
'the Project menu..
Dim fso As New FileSystemObject
Dim file As TextStream
Rate Checks username and Password from a text file using Filescripting.
(2(2 Vote))
Set file = fso.OpenTextFile(App.Path & "/user.txt", ForReading, False)
While Not file.AtEndOfStream
If file.ReadLine = Trim(Text1.Text) & ";" & Trim(Text2.Text) Then
MsgBox "Login sucessful"
Exit Sub
End If
Wend
MsgBox "Login Fail"
file.Close
End Sub
Private Sub Command2_Click()
Set file = fso.OpenTextFile(App.Path & "/user.txt", ForAppending, True, TristateUseDefault)
file.WriteLine vbCrLf & Text3.Text & ";" & Text4.Text
MsgBox "Login Created"
End Sub
Checks username and Password from a text file using Filescripting. Comments
No comments yet — be the first to post one!
Post a Comment