Timer in subform
ib000904
Member Posts: 19
We got one main form which contains two subforms, each looking at the "Sales Line"-table from different views.
How can we make all forms show additions to the sales lines almost immediately as they are entered in the database?
Looks like the 'ontimer' property (with CurrForm.Update the on_timer section of the C/AL) only functions for the active form, but we also want the inactive ones to be updated.
How can we make all forms show additions to the sales lines almost immediately as they are entered in the database?
Looks like the 'ontimer' property (with CurrForm.Update the on_timer section of the C/AL) only functions for the active form, but we also want the inactive ones to be updated.
0
Comments
-
Using the Timer for the Main Form, Update the form as well as call functions to the Subforms which would cause them to Update.
Form - OnTimer() CurrForm.UPDATE; CurrForm.SubForm.UpdateTableFunction; CurrForm.OtherSubForm.UpdateTableFunction;
Or if this will do the trick (not sure off the top of my head), CurrForm.SubForm.UPDATE, called from the Timer event.0 -
ib000904 wrote:We got one main form which contains two subforms, each looking at the "Sales Line"-table from different views.
Do I understand correctly - all 3 forms look at the "Sales Line" table, or only the two subforms?ib000904 wrote:How can we make all forms show additions to the sales lines almost immediately as they are entered in the database?
Looks like the 'ontimer' property (with CurrForm.Update the on_timer section of the C/AL) only functions for the active form, but we also want the inactive ones to be updated.
If it is all 3 forms, can you make new entries in all 3 or only the main form?
Also, do you see both subforms at all times, or only one of them (like on a Tab-control maybe)?
If the insert is only allowed on the main form, then it's easy. Just call an update to Currform.Subforms.UpdateFunction (where UpdateFunction contains the code "Currform.Update(false);") in the OnAfterGetCurrRecord Trigger.
If you can edit on the subforms as well, then the best (besides the timer) you can do, is on the Subform.OnDeactivate, call a Currform.Update AND Currform.otherSubform.UpdateFunction.0
Categories
- All Categories
- 75 General
- 75 Announcements
- 66.7K Microsoft Dynamics NAV
- 18.8K 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
- 610 NAV Courses, Exams & Certification
- 2K Microsoft Dynamics-Other
- 1.5K Dynamics AX
- 253 Dynamics CRM
- 103 Dynamics GP
- 6 Dynamics SL
- 1.5K Other
- 991 SQL General
- 383 SQL Performance
- 34 SQL Tips & Tricks
- 28 Design Patterns (General & Best Practices)
- Architectural Patterns
- 9 Design Patterns
- 4 Implementation Patterns
- 53 3rd Party Products, Services & Events
- 1.6K General
- 1K General Chat
- 1.6K Website
- 77 Testing
- 1.2K Download section
- 23 How Tos section
- 249 Feedback
- 12 NAV TechDays 2013 Sessions
- 13 NAV TechDays 2012 Sessions