MBMSOFT
03-23-2010, 01:16 PM
Any idea how to stop access warnnigs in vba when input value is diferent then validation rule or diferent then input mask format....
I want to have my message ...i don't need access warnning
i tried with error handling but i didn't succsed ,docmd.setwarnnings false doesn't prevent from messagess as well ....
Khalid_Afridi
03-23-2010, 01:26 PM
Any idea how to stop access warnnigs in vba when input value is diferent then validation rule or diferent then input mask format....
I want to have my message ...i don't need access warnning
i tried with error handling but i didn't succsed ,docmd.setwarnnings false doesn't prevent from messagess as well ....
What message you are getting? to just set the warning off and on do this:
DoCmd.SetWarnings False
your code....
.......
.......
DoCmd.SetWarnings True
Mr. B
03-23-2010, 01:37 PM
I you do not want the validation rule to cause the display of the message, remove the validation rule at the table level.
MBMSOFT
03-23-2010, 02:01 PM
it's a metter when i have validation rule or input mask in control and when if it is wrong i have acceess message like it is not aloowed that value , but i dont want that message
ex: inputmask 0000;;
if i enter characters like"SADSAD" INSTEAD OF NUMBERS
I GOT ACCESS MESSAGE ... I'D LIKE TO TURN OF THAT MESSAGE BUT STIIL TO HAVE THE INPUT MASK
WARRNINGS OFF DOSENT PREVENT THAT ACCESS MESSAGE
Khalid_Afridi
03-23-2010, 11:54 PM
so you want to show your own msgs to appear...
Check this (http://www.learnaccessnow.com/chap03a.html) for validateion rules.
The Validation Text property is the message displayed by Access if a value does not meet your validation rule. In other words, if your validation rule checks whether a value is outside a certain range, and the value is outside that range, Access displays the validation text in a dialog box. As an example, let's assume that the following are your settings for the Validation Rule and Validation Text properties:
http://www.learnaccessnow.com/figs/fig0304b.jpg
In this case, if you tried to enter a value lower than 20 in the field, then Access would display an error message dialog box, as shown in Figure 3-5.
http://www.learnaccessnow.com/figs/fig0305.jpg
Figure 3-5 A validation rule error message dialog box.
MBMSOFT
03-24-2010, 08:33 AM
ok, thanks a lot
and what about input mask.....
when the entered value is different then it is required format defined in inpput mask
how i can put my message
ex : 000\-00000\-00;;
if i enter
123-FGDSASG-00
I WANT TO HAVE MY MESSAGE
You don't get your own messages for input masks.