473,396 Members | 1,900 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

Password Verification Form...

All,
This should be very simple for you VB programmers, I am just a
beginner and am stuck! It should be very simple... what am I not
doing right?

Dim PW As String

PW = Me.Password

If PasswordVerify <> Password Or IsNull(PasswordVerify = True)
Then
MsgBox "Password you've entered do not match. Please Retype."
Me.PasswordVerify = ""
[Password].SetFocus
Me.Password = PW
Else: MsgBox "Your new password has successfully been set."
End If
I have 2 boxes, "Password" and "PasswordVerify". Password box is
based on a Table while PasswordVerify is just an unbound box. If user
enters an password that do not match, it will revert back to its
original password. I named it PW. But apparently, me.password = pw
did not do so. What did I code wrong?

Thanks.
PC
Nov 13 '05 #1
1 2157
pe******@yahoo.com (PerryC) wrote in
news:ea*************************@posting.google.co m:
All,
This should be very simple for you VB programmers, I am
just a
beginner and am stuck! It should be very simple... what am I
not doing right?

Dim PW As String

PW = Me.Password
The next line of code is bad. If PasswordVerify <> Password Or IsNull(PasswordVerify =
True)
Then

it should be:
If PasswordVerify <> Password Or IsNull(PasswordVerify)

because
(PasswordVerify = true) can never be null.

You'd simplify everything however but inverting the logic

If me.Password = PasswordVerify then
msgBox "Your new password has successfully been set"
else
msgBox " whatever"
me.PasswordVerify = null
me.Password.setfocus
me.Password = PW
End If

Note password = passwordverify will be false if either side is
null. That makes the whole thing easier to manage.

Bob Quintal

MsgBox "Password you've entered do not match. Please Retype." Me.PasswordVerify = ""
[Password].SetFocus
Me.Password = PW
Else: MsgBox "Your new password has successfully been
set."
End If
I have 2 boxes, "Password" and "PasswordVerify". Password box
is based on a Table while PasswordVerify is just an unbound
box. If user enters an password that do not match, it will
revert back to its original password. I named it PW. But
apparently, me.password = pw did not do so. What did I code
wrong?

Thanks.
PC


Nov 13 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: Richard M | last post by:
Can anyone please lend me a hand, I'm trying to design a cookie based password system. I have managed to do everything bar one thing that is driving me crazy. I have a MYSQL database called...
2
by: Rickard | last post by:
OK. I have the need on a form submit to pass the data to anther system that require a login and password only I want to automate the process in an server side asp file and then process the...
2
by: MLH | last post by:
What's the simplest way to allow a user of an A97 app to change password?
3
by: Susan Bricker | last post by:
I would like to have a transparent command button on my Main Menu to cause an Inputbox( ) to be displayed for the user to enter a password. This is to control the enabling of Bypass Key (shift). ...
9
by: kwindham | last post by:
This program doesn't seem like it should be too hard, but I cannot figure it out. Here is the assignment: Password Verifier - Write a program to verify passwords, satisfying the following...
0
by: pwilliams | last post by:
NCOALink Change of Address Verification Each year over 40 million Americans change their mailing addresses. This change is equivalent to every person in California deciding to change addresses...
3
by: Saqib Ali | last post by:
is there a way to enforce password history verification when using Directory.Entry.Invoke("SetPassword", newPasswdStr)??? saqib http://www.full-disk-encryption.net
1
by: wideasleep | last post by:
Hello Everyone, I have to set up a electronic form for recording additions to a chemical proccess where I work. Think of this as a big kitchen but instead of food products we have chemicals. So...
1
by: fabiola1 | last post by:
I'm using Ms-access 2003.I have a table called users it has two fields called Username and password.I have created a form called security interface.where the user enters the username and password.Can...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.