Hi
I need to do this:
After I have compiled an edit form, I want to do a check into the database on another table to see if there is a correspondence between data. If yes, the program must save, otherwise it must display an alert and avoid saving.
So it's possible to stop nuBuilder from saving data after a check in Custom Code/Before Save, like "return false" in Javascript?
Thank you
Alex
Welcome to the nuBuilder forums!
Please register and login to view forums and other content only available to registered users.
Please register and login to view forums and other content only available to registered users.
Stop saving after a check in before save
-
- Posts: 38
- Joined: Tue Jun 05, 2012 2:40 pm
- Location: Bologna, Italy
- Contact:
-
- Site Admin
- Posts: 2786
- Joined: Mon Jun 15, 2009 2:23 am
- nuBuilder Version: 4.5
- Been thanked: 3 times
Re: Stop saving after a check in before save
Alex,
If you attach a message to a variable named $errorMessage in the Before Save event, this message will not continue to save but return its self as a warning.
If $errorMessage remains empty a record will be saved.
Steven
If you attach a message to a variable named $errorMessage in the Before Save event, this message will not continue to save but return its self as a warning.
If $errorMessage remains empty a record will be saved.
Steven
-
- Posts: 38
- Joined: Tue Jun 05, 2012 2:40 pm
- Location: Bologna, Italy
- Contact:
Re: Stop saving after a check in before save
Steven
Thank you for your answer.
I did the job with ajax, so that I can check correspondence directly from javascript.
Alex
Thank you for your answer.
I did the job with ajax, so that I can check correspondence directly from javascript.
Alex