Hello....
I've searched the forum but i didn't found solution for my problem...
In Vendor Card:
I want that if the address is blank then appears a confirm windows that shows the user if he wants to continue or not.
If choose not then stay on the record, if choose yes then go to next or previous record, insert.... the normal behavior of the form.
Can someone help me with this problem?
Junior Consultant & Developer in Dynamics NAV
"I'm worse at what I do best
And for this gift I feel blessed
Our little group has always been
And always will until the end"
Nirvana - Nevermind - Smells Like Teen Spirit
0
Answers
do you want some kind of mandatory field validation to occur?
PS: You should try to use table validation whereever possible.
http://www.BiloBeauty.com
http://www.autismspeaks.org
The OnQueryCloseForm() solves my problem.
But on the other "movements", it's hell.....
One example:
I'm in Vendor Card No. F001
The address is blank, but i want to move to the next record...
It should appear one dialog that says "The address is not fill. Want to continue?"
If the user says yes, it goes to the next record, if it says no it stays on the No. F001
Do you understand my big problem?
I want that in moving records and create new........
"I'm worse at what I do best
And for this gift I feel blessed
Our little group has always been
And always will until the end"
Nirvana - Nevermind - Smells Like Teen Spirit
RIS Plus, LLC
????????
I am the developer of the company partner......
Don't understant what your purpose with that answer..............
"I'm worse at what I do best
And for this gift I feel blessed
Our little group has always been
And always will until the end"
Nirvana - Nevermind - Smells Like Teen Spirit
In NAV you don't have save actions, as you know, so you can't easily catch that event on a form level. You shouldn't even do ANY data validation on a form level to begin with, that is definitely not the right place to put validation code. So instead of trying to make the system do something that it was never designed to do, you think about what the system IS designed to do. Think along the lines of how the system usually works with data validation and when checks are performed.
I would personally go along the lines of adding this check to the release process, and not allow an order to be released with an empty address.
RIS Plus, LLC
Don't know why are you so suprised.....
Do you know why i love Navision?
Because it does whatever you want to do....
By one mean or the other, it does always what you pretend to do.....
But this is an anormal exception....
I don't want the fields to be true validated, I want only one warning to the user, nothing else......
"I'm worse at what I do best
And for this gift I feel blessed
Our little group has always been
And always will until the end"
Nirvana - Nevermind - Smells Like Teen Spirit
RIS Plus, LLC
Ignoring the message. It's hard to program when it's "sometimes OK" to do one thing or another.
Best to either make the address field mandatory or not.
http://www.BiloBeauty.com
http://www.autismspeaks.org
Function Release
Andwian
As many NAV developpers, I have worked on this topic but did not found out the perfect solution. Using the form triggers, there is always a way to insert a record without the requested datas.
From my experience, there are two ways to deal with mandatory fields :
1°) Use a Vendor creation Card. This card could be running on a temporary record (have a look to the Todo creation process in the NAV CRM Module). From the card, a posting function perform the field value checks, and insert the record in the table if no errors occured. A bit of development to Do...
2°) Block the vendor as long as the requested field are to filled (using the standard "blocked" field). If the fields are not filled, no one could use the vendor in an order or in general journal lines... which make the fields mandatory (in a way).
Hope that helps...
It is definitely not "standard Navision practice" and should be avoided for many reasons. But, it CAN be done. And it's why I have come to like Navision so much as well. It can do almost anything!
I've come to a solution that best apply for what i want to do......
A new function
That will trigger on In Navision V4, the OnNewRecord doens't work because the CurrForm.Update
Thank you all for all the suggests......
"I'm worse at what I do best
And for this gift I feel blessed
Our little group has always been
And always will until the end"
Nirvana - Nevermind - Smells Like Teen Spirit