Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations derfloh on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Msgbox validation? 1

Status
Not open for further replies.

agray7501

IS-IT--Management
Feb 21, 2002
3
US
I have created a form that requires data entry.
I want to the user to validate the data they entered before a save occurs, this event would happen when the user presses the SAVE button, using a message box but I am having a problem with the syntax of the code. If anyone has any helpful hints it would be great.

Here is what I want it to look like

____________________________________________
DATA ENTRY
--------------------------------------------
IS THIS WHAT YOU WANT?

PIN: 15 - A - 35
Applicant Name: Alex
Application Description: MEMO
--------------------------------------------
vbYesNo

If Yes then save data entered
If No then close message box and allow user to edit data.
_______________________________________________________
Also, can anyone suggest a good book or guide for ACCESS 2002-03 that would be helpful for this kind of stuff?
-----------------------------------------------------
Thanks, AL
 
well, if you're looking for something even a little complicated as a prompt, then use a popup form...

otherwise, you can use the chr(number) function to insert line breaks in your msgbox message...

e.g.

msgbox "blah, " & tbxText & chr(13) & chr(10) & "more blah"

to give:

blah someText
more blah

remember to use both lineFeed and carrageReturn to make a new line, it requires both for some reason...
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top