How do i use a preset password on my visual basic program that will check first the username and and then the password and make sure that if username is this then the password should be that...

Hi,
U must go with 'if else' conditions-
like

if 'object' = 'username1' then 
 if 'object'='password' then 
 login = true
 else
 login= false
 msgbox"plz enter valid password for this user"
 endif
else
 msgbox"plz enter valid user name"
endif

where 'object' is a filed of your database containig the username and password or may be you can use textbox.

if u r using textbox then u must specify the user name and password in the coding or use a inputbox to modify lateron.

I m not elaborating much hope u understand.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.