Running Balance Field

airam
Member Posts: 91
hi all,
i'm quite new to NAV and i need to add a new column in the Vendor Ledger Entry Table to keep a running balance of the amount. i.e. "running balance" := "running balance" + amount .. but it keeps showing zeros when i run the table. how shall i go about it please? thanks a lot
i'm quite new to NAV and i need to add a new column in the Vendor Ledger Entry Table to keep a running balance of the amount. i.e. "running balance" := "running balance" + amount .. but it keeps showing zeros when i run the table. how shall i go about it please? thanks a lot
0
Comments
-
The amount field is a FLOWFIELD. That means, that i has no value are stored in the table self. It's is a referencefield with a calcformula to a other table (here Detailed Vendor Ledg. Entry) and to a field there (here also the Amount field in the table Detailed Vendor Ledg. Entry).
So, what should the "Running balance" display? Why do you need it, whats the reason?
Should this be the whole amount of the vendor?
RegardsDo you make it right, it works too!0 -
the main request from the client is that when he views the vendor ledger entries from the vendor card he would see a running balance besides the amount, which yes eventually the last amount would be equal to the total amount
and i need to do the same for the Item Ledger Entry on the Quantity field which is a normal decimal field..
any help pls?
thanks and regards0 -
Hi Airam,
It is possible but is a lot of work on the server - may cause major performance issues. What you do is in the OnAfterGetCurrentRecord - copy the filters of the record variable REC to a variable and loop through the variable until current record totaling the value. Display the value in the list form0 -
it can run fast if the vendor has not a lot of entries and the table has not many records. But with the time .... it comes slower and slower ...... and your customer scream ...... So, tell him the pro and contra and ask if he need it really. Why he need it? only to have a history what was the amount before and after the posting? So you can also store this values in a separate field and fill these field in the posting codeunit. But this is also a lot of work (for example u must also handle the undo postings) and in my eyes these are not needed datas .....Do you make it right, it works too!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