Using a temp table in a factbox

generaljim99
Member Posts: 4
I'm not sure if I'm going down the right road, but what I'm attempting to do is add a Factbox to the Sales Order page in NAV 2017 based on which Sales Line is focused on. This Factbox needs to summarize the Quantities from the Bin Content table by matching the Item, Location Code, and Unit of Measure fields from the Sales Line. I've tried a few things and ended up trying to set the new Factbox up with the Bin Content table as the source, and set the SourceTableTemporary property to Yes. I then created a new local function (InitTempTable) that tries to populate the temp table using the SubPageLink that is set in Page 42 and calling it from the OnOpenPage trigger in the new Factbox. In Page 42 I am using using the same ProviderID used by the Sales Line Factbox, and a different SubPageView and SubPageLink. I was hoping that the SubPageLink would send in a filter set to my new Factbox, but alas no. The Factbox shows nothing. The debugger shows that there are no filters set at all there. I can't use a trigger in Page 42 (or can I somehow?) because I can't find a trigger with the Name defined for the Factbox Page in Page 42. Am I missing something obvious? Or even not so obvious? Any help would be appreciated!
0
Answers
-
why not using existing FactBox?
Just checked for sales order -> codeunit7171 function CalcAvailableInventory, for instance,
has SalesLine as a parameter
so you can have any numbers being calculated for you current sales line here.0 -
Create the InitTempTable as Global on the Factbox Page. Then call this function in your Main Page (in this case Sales Order) in your onAfterGetCurrRecord through the Factbox Page.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