Access validating

It uses routines, often called "validation rules" "validation constraints" or "check routines", that check for correctness, meaningfulness, and security of data that are input to the system.

Set Focus is Valid = False End If If (Ord_Rcvd_Dt Ord_Comp_Dt.

Value) Then Msg Box "Order Complete Dt should be greater then Order Recv Date! Set Focus is Valid = False End If Chk Fld = is Valid End Function So my question is how I can overcome this error and I want user to enter the correct value and can't be null and even if just entering date and hitting save button it should also fire at save button too. for reply, I used your method but it seems Validation rule property is not working properly in access 2003, if I entered wrong date or kept null and hit the tab key it didn't fire the event, it works if i enter the date and remove the date and hit tab it says it cannot be null but it doesn't fire for wrong date.

But you can't exit because it keeps firing the message!

Why is it not enough for you to check the fields before saving the record?

Cancelevent, so how i can stop popping this message. for reply, I used your method but it seems Validation rule property is not working properly in access 2003, if I entered wrong date or kept null and hit the tab key it didn't fire the event, it works if i enter the date and remove the date and hit tab it says it cannot be null but it doesn't fire for wrong date.

I am tired that my validation is not working, there are few more validation this one is easiere one its not working properly. It should stop user there unless it enters right date. The situation you described happens because you entered the code on field level.After that I get no messages, only the record is still in editing mode as it should be, not allowing to save it before it meets the criterion set before. If b Value is less than 30 I get the message I asked. I used ur code at form level beforeupdate, but nothing happened ,my cursor went to next field, it works only if I hit the save button, so I used the code at field level beforeupadte it works there if I hit tab it fires the trigger when criteria not matched, but issue is that it doesn't allow me to do any changes to be made in Indoc or Indoc2 or product field and continously it fires the message. Why is it not enough for you to check the fields before saving the record? The situation you described happens because you entered the code on field level.After that I get no messages, only the record is still in editing mode as it should be, not allowing to save it before it meets the criterion set before. You keep insisting on field level checking, but that is not always easy... You should have this code to run on form's before update property!You keep insisting on field level checking, but that is not always easy... Hi H, Thanks for ur reply, I got it what u r saying, if Before update works at form level then it wouldn't be problem, user says we want that after entering the wrong value it should fire the trigger so I am trying to meet their requirement, can you tell me how I should convince user saying that this will work only at form level,while saving your record.I am not that expert in access so I dont know how to explain them.Uncheck "The key is provided for me automatically" and enter and confirm your Network key.

Tags: , ,