Customer Card - Implementing Mandatory Fields

Gon_M.
Member Posts: 34
Hi experts:
I'm trying to implement mandatory fields in customer card. I chose this alternative:
- DelayedInsert = Yes, in Customer Card Form
- Validate code into the customer card
it worked fine, but I have a problem because I have to validate the contact field, which insert the new contact as a contact of the new customer, but this new customer don't have "No.", because new customer was not be inserted yet, so I obtain an error who say that doesn't exist the customer No.=''.
Someone have a symilar problem?
Thanks in advance.
I'm trying to implement mandatory fields in customer card. I chose this alternative:
- DelayedInsert = Yes, in Customer Card Form
- Validate code into the customer card
it worked fine, but I have a problem because I have to validate the contact field, which insert the new contact as a contact of the new customer, but this new customer don't have "No.", because new customer was not be inserted yet, so I obtain an error who say that doesn't exist the customer No.=''.
Someone have a symilar problem?
Thanks in advance.
0
Answers
-
Yes.
I would suggest to set the customer by default to blocked. Add your logic on the validate of the blocked field. And remove the delayed insert property.0 -
One way to do this is on the form triggers, test the Contact No. field.
Allow the user to Insert without the Check but not close or move the record navigation
Form - OnQueryCloseForm() : Boolean
IF "Contact No." = '' THEN
EXIT(FALSE);
You will also need it on some of these
Form - OnNewRecord(BelowxRec : Boolean)
Form - OnInsertRecord(BelowxRec : Boolean) : Boolean
Form - OnNextRecord(Steps : Integer) : Integer
Form - OnModifyRecord() : BooleanAnalyst Developer with over 17 years Navision, Contract Status - Busy
Mobile: +44(0)7854 842801
Email: david.cox@adeptris.com
Twitter: https://twitter.com/Adeptris
Website: http://www.adeptris.com0 -
Thank you for reply .
I'm going to try ara3n's solution because is more compatible with my scenario.
Thank you again.0
Categories
- All Categories
- 73 General
- 73 Announcements
- 66.6K Microsoft Dynamics NAV
- 18.7K NAV Three Tier
- 38.4K NAV/Navision Classic Client
- 3.6K Navision Attain
- 2.4K Navision Financials
- 116 Navision DOS
- 851 Navision e-Commerce
- 1K NAV Tips & Tricks
- 772 NAV Dutch speaking only
- 617 NAV Courses, Exams & Certification
- 2K Microsoft Dynamics-Other
- 1.5K Dynamics AX
- 320 Dynamics CRM
- 111 Dynamics GP
- 10 Dynamics SL
- 1.5K Other
- 990 SQL General
- 383 SQL Performance
- 34 SQL Tips & Tricks
- 35 Design Patterns (General & Best Practices)
- 1 Architectural Patterns
- 10 Design Patterns
- 5 Implementation Patterns
- 53 3rd Party Products, Services & Events
- 1.6K General
- 1.1K General Chat
- 1.6K Website
- 83 Testing
- 1.2K Download section
- 23 How Tos section
- 252 Feedback
- 12 NAV TechDays 2013 Sessions
- 13 NAV TechDays 2012 Sessions