Form does not update table correctly

ben5000
Member Posts: 110
Hi experts,
Here is the situation:
I've written a function whose purpose is to check a record and set a boolean to TRUE/FALSE accordingly.
I call it in the the sourceExpr property on the dedicated form.
If the process reaches the end of the function then the boolean is set to true.
It works fine on form level, every line of the record which reached the end of the function is marked with true.
But when going into the table it is not updated and every record is set to false. I've to click every line (on the form) to update them and then
it's okay. So it seems that I need to refresh every line at form level in order to have them written in the database.
I tried several things but it didn't work so have you any idea why it is not working?
Many thanks,
Here is the situation:
I've written a function whose purpose is to check a record and set a boolean to TRUE/FALSE accordingly.
I call it in the the sourceExpr property on the dedicated form.
If the process reaches the end of the function then the boolean is set to true.
It works fine on form level, every line of the record which reached the end of the function is marked with true.
But when going into the table it is not updated and every record is set to false. I've to click every line (on the form) to update them and then
it's okay. So it seems that I need to refresh every line at form level in order to have them written in the database.
I tried several things but it didn't work so have you any idea why it is not working?
Many thanks,
0
Comments
-
is there any reason to set the function in Source expression?
why dont you call the function in OnAfterGetRecord trigger?0 -
Yes because I also need to print a message describing the error on the record.
When calling the function in the SourceExpr Navision handles the update of the form.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