Please support our Visual Basic 4 / 5 / 6 advertiser: Programming Forums
Views: 1113 | Replies: 9
![]() |
hi,
The below coding help u to store the username and password in arrays and to retreive it.
Dim user(20) As String 'Username Array Declaration
Dim pwd(20) As String 'Password Array Declaration
Dim i As Integer
Private Sub cmdadd_Click()
user(i) = txtuser.Text
pwd(i) = txtpwd.Text
i = i + 1
txtuser.Text = ""
txtpwd.Text = ""
End Sub
Private Sub Cmdsearch_Click()
a = txtuser.Text
For i = 0 To 20
If user(i) = a Then
txtpwd.Text = pwd(i)
End If
Next
End Sub
Private Sub Form_Load()
i = 0
End Sub
al the best
Shailu
The below coding help u to store the username and password in arrays and to retreive it.
Dim user(20) As String 'Username Array Declaration
Dim pwd(20) As String 'Password Array Declaration
Dim i As Integer
Private Sub cmdadd_Click()
user(i) = txtuser.Text
pwd(i) = txtpwd.Text
i = i + 1
txtuser.Text = ""
txtpwd.Text = ""
End Sub
Private Sub Cmdsearch_Click()
a = txtuser.Text
For i = 0 To 20
If user(i) = a Then
txtpwd.Text = pwd(i)
End If
Next
End Sub
Private Sub Form_Load()
i = 0
End Sub
al the best
Shailu
•
•
Join Date: Jul 2007
Location: Philippines
Posts: 255
Reputation:
Rep Power: 0
Solved Threads: 28
•
•
•
•
Ok if anyone knows how to put
usernames and passwords in
arrays and declare it and i
need a full directions on
the code!
Thanks Seeleo6
You don't mention if the usernames and passwords is to be saved or to be retrieved from the database or wherever you store/save your data. be specific to your post.
P.S can you say please? it looks like to me you're giving a command...
regards
jireh
•
•
Join Date: Jul 2007
Location: Philippines
Posts: 255
Reputation:
Rep Power: 0
Solved Threads: 28
A conclusion is the place where you got tired of thinking. http://www.martin2k.co.uk/forums/index.php?showforum=4
http://www.a1vbcode.com/a1vbcode/vbforums/Forum3-1.aspx
http://www.developerfusion.co.uk/for...orum&ForumID=4
•
•
Join Date: Jul 2007
Location: Philippines
Posts: 255
Reputation:
Rep Power: 0
Solved Threads: 28
hiding your database is maybe good but its more fine if you put a password in your database so that even they can see your database still they can't see the data inside on it, right?!
A conclusion is the place where you got tired of thinking. http://www.martin2k.co.uk/forums/index.php?showforum=4
http://www.a1vbcode.com/a1vbcode/vbforums/Forum3-1.aspx
http://www.developerfusion.co.uk/for...orum&ForumID=4
![]() |
•
•
•
•
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)





Linear Mode