1.11M Members

CODE FOR LOG IN USING VB 2010 CONNECTED TO ACCESS DATABASE

 
0
 

Hello guys, I'm new to vb 2010 and it screws me alot...
can you please help me to code my login form containing 2 textboxes: usrn and pass. my database Account has two columns, namely Username and Password...
one thing is, I thought it was the same as Vb 6.0, but i was blanked when i've started using vb 2010. when i add data source to my vb application, i thought it was already done, but when i run the program, there's no change even i type wrong username and password combinations. I'm sorry, i just went blank...and i badly need your help now :-/

 
0
 

Using This you can find a string.

Try something like this in a connect button click:

Try
    Dim con As New OleDBConnection(Provider=Microsoft.ACE.OLEDB.12.0;Data Source=C:\myFolder\myAccess2007file.accdb;Jet OLEDB:Database Password=" & txtPassword.Text & ";")   'Assuming the password textbox is name txtPassword.
Catch ex As Exception
    MsgBox(ex.ToString())
End Try
You
This article has been dead for over six months: Start a new discussion instead
Post:
Start New Discussion
View similar articles that have also been tagged: