Click here to Skip to main content
15,910,211 members
Home / Discussions / Visual Basic
   

Visual Basic

 
QuestionCrystal Reports Dynamic Parameter Support within vb.net Pin
manisghouri12-Mar-07 8:45
manisghouri12-Mar-07 8:45 
QuestionPicturebox Control Question Pin
JohanSturk12-Mar-07 7:08
JohanSturk12-Mar-07 7:08 
AnswerRe: Picturebox Control Question Pin
M-Hall12-Mar-07 7:42
M-Hall12-Mar-07 7:42 
AnswerRe: Picturebox Control Question Pin
JUNEYT12-Mar-07 7:44
JUNEYT12-Mar-07 7:44 
GeneralRe: Picturebox Control Question Pin
JohanSturk12-Mar-07 8:31
JohanSturk12-Mar-07 8:31 
GeneralRe: Picturebox Control Question Pin
M-Hall12-Mar-07 8:50
M-Hall12-Mar-07 8:50 
GeneralRe: Picturebox Control Question [modified] Pin
JUNEYT12-Mar-07 10:08
JUNEYT12-Mar-07 10:08 
QuestionPLEASE!!!! REALLY STUCK ON THIS ONE Pin
peteyshrew12-Mar-07 4:51
peteyshrew12-Mar-07 4:51 
im creating a form where users can login to a seperate form using a login name and password. I'm trying to compare the users imput for the login to a feild in MS Access and the same with password input in a seperate feild in the same table(PCBank.mdb). if input is correct go to form2.

if anyone can help it would be greatly appreciated. code below is my attempt



Imports System.Data.OleDb
Public Class Form1
Dim conn As OleDbConnection
Dim comm As OleDbCommand
Dim dr As OleDbDataReader
Dim da As OleDbDataAdapter

Private Sub connect()
conn = New OleDbConnection
conn.ConnectionString = "provider=microsoft.jet.oledb.4.0;data source=|datadirectory|\PCBank.mdb"
conn.Open()
comm = New OleDbCommand
comm.Connection = conn
comm.CommandType = CommandType.Text
End Sub

Private Sub DisplayRecord()
Me.txtid.Text = dr.GetString(0)
Me.txtpass.Text = dr.GetString(1)
End Sub

Private Sub btnlogin_Click(ByVal sender As
System.Object, ByVal e As System.EventArgs) Handles btnlogin.Click
connect()
comm.CommandText = "select * from Managers where id like '" & txtid.Text & txtpass.Text & "%'"

If txtid.Text = "Managers" = dr.GetString(0) And txtpass.Text = "Managers" = dr.GetString(1) Then
My.Forms.Form2.Show()
Me.Close()
End If

End Sub
End Class

AnswerRe: PLEASE!!!! REALLY STUCK ON THIS ONE Pin
Christian Graus12-Mar-07 5:05
protectorChristian Graus12-Mar-07 5:05 
AnswerRe: PLEASE!!!! REALLY STUCK ON THIS ONE Pin
jhoga12-Mar-07 5:07
jhoga12-Mar-07 5:07 
QuestionUser Control Problem Pin
TCHamilton12-Mar-07 4:49
TCHamilton12-Mar-07 4:49 
AnswerRe: User Control Problem Pin
Star Vega22-Mar-07 11:09
Star Vega22-Mar-07 11:09 
QuestionChecking string value Pin
harveyhanson12-Mar-07 4:27
harveyhanson12-Mar-07 4:27 
AnswerRe: Checking string value Pin
nlarson1112-Mar-07 5:04
nlarson1112-Mar-07 5:04 
AnswerRe: Checking string value Pin
prakash J13-Mar-07 4:45
prakash J13-Mar-07 4:45 
GeneralRe: Checking string value Pin
harveyhanson13-Mar-07 5:56
harveyhanson13-Mar-07 5:56 
Questionstr Value question Pin
harveyhanson12-Mar-07 4:26
harveyhanson12-Mar-07 4:26 
AnswerRe: str Value question Pin
nlarson1112-Mar-07 5:02
nlarson1112-Mar-07 5:02 
AnswerRe: str Value question Pin
jhoga12-Mar-07 5:40
jhoga12-Mar-07 5:40 
GeneralRe: str Value question Pin
harveyhanson12-Mar-07 5:46
harveyhanson12-Mar-07 5:46 
GeneralRe: str Value question Pin
M-Hall12-Mar-07 5:59
M-Hall12-Mar-07 5:59 
Questioninheriting values among forms Pin
manni_n12-Mar-07 3:25
manni_n12-Mar-07 3:25 
AnswerRe: inheriting values among forms Pin
nlarson1112-Mar-07 5:00
nlarson1112-Mar-07 5:00 
AnswerRe: inheriting values among forms Pin
Christian Graus12-Mar-07 5:07
protectorChristian Graus12-Mar-07 5:07 
Questionneed help on admin access login screen Pin
peteyshrew12-Mar-07 3:10
peteyshrew12-Mar-07 3:10 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.