Problem with report....

voodoo
Member Posts: 82
Hi,
I have some problem with my report(with new one - the old one works great).........well, I have 3 dataitems:
Classes
-->Item
---->Value Entry
The old one gives me SUM of "Sales Amount (Actual)"(Value Entry) grouped by classes.
The new one should be the same but I need also to show data by months:
<labels> class class description jan feb mar .... dec
+
+----+----+---+
+-
I tried to put this into OnAfterGetRecord (value Entry) but something is wrong
ValueEntry2 record Value Entry
PeriodStartDate[13] date
SalesAmount[12] decimal
Thnx in advance
I have some problem with my report(with new one - the old one works great).........well, I have 3 dataitems:
Classes
-->Item
---->Value Entry
The old one gives me SUM of "Sales Amount (Actual)"(Value Entry) grouped by classes.
The new one should be the same but I need also to show data by months:
<labels> class class description jan feb mar .... dec
+
+----+----+---+
+-
I tried to put this into OnAfterGetRecord (value Entry) but something is wrong

FOR i := 1 TO 12 DO BEGIN ValueEntry2 := "Value Entry"; ValueEntry2.SETRANGE("Posting Date",PeriodStartDate[i],PeriodStartDate[i + 1] - 1); IF ValueEntry2.FIND('-') THEN REPEAT SalesAmount[i] := ValueEntry2."Sales Amount (Actual)"; UNTIL ValueEntry2.NEXT = 0; END;
ValueEntry2 record Value Entry
PeriodStartDate[13] date
SalesAmount[12] decimal
Thnx in advance

misha fka voodoo
0
Comments
-
I don't see a
ValueEntry2.CALCSUMS("Sales Amount (Actual)");
to calculate your SumIndexField.No support using PM or e-mail - Please use this forum. BC TechDays 2024: 13 & 14 June 2024, Antwerp (Belgium)0 -
Well I would try to explain....I think that's not a point in SUM, because, like I said, the old one works great, on OnPreDataItem of Value Entry I put:
CurrReport.CREATETOTALS("Invoiced Quantity","Sales Amount (Actual)","Discount Amount");
and in it's property GroupTotalFields: Item No.
My problem is how can I show "Sales Amount (Actual)" from Value Entry by months(example user may choose a year(enter some four digits(1999......2005) and in the report I would have to show months(by names or by numbers(1..12))
I hope that you understand what I need.........and sorry for my englishmisha fka voodoo0
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