How to count the total number of the customers

Horse06
Member Posts: 496
Hi Expert, I need your help and advice.
In the customer Sales Analysis report, I have three tables: Customer Table, Value Entry Table and Res. Ledger Entry Table. How to count the total number of the customers based on the date range and put the total number at the customer footer. Thanks!
In the customer Sales Analysis report, I have three tables: Customer Table, Value Entry Table and Res. Ledger Entry Table. How to count the total number of the customers based on the date range and put the total number at the customer footer. Thanks!
0
Comments
-
-
Thank you Mark! I have tried the following.
Declare intcounter as decimal
In the Customer OnaftergetREcord
intcounter :=1
In the customer onpreDataitem
CurrReport.CREATETOTALS(intCounter);
In the Customer footer, intCounter shows the total number of all of the customers in the system (e.g in the following report, total number of customers is showing as 330 instead of 3). How to get the correct numbers of the total customers as below:
Customer Sales Analysis
5/10/13-5/20/13
Customer A
Customer B
Customer C
Total number of the customers: 3
Thank you!0 -
What about forgetting the CREATETOTALS-function and put intcounter :=intcounter + 1 in the OnAfterGetRecord-trigger of the Customer-DataItem?No support using PM or e-mail - Please use this forum. BC TechDays 2024: 13 & 14 June 2024, Antwerp (Belgium)0
-
No, it doesn't work, still showing the total number of the customers. Thank you!0
-
Are you skipping records or only showing customers with details?0
-
Thank you for your response! I didn't skip any records. I also tried to view both the summary and detailed report,
but have the same result. I tested using one day report and even thought there are a total of 10 records showing, but
the numbers is showing 500. Thank you!0 -
Hi expert, is there any solutions for this? Thank you!0
-
Is the date range applied on the Value Entry Table? If my understand is correct, I think code should be put as the following:
Declare FirstTime as boolean.
In Value Entry Table - OnPreDataItem
FirstTime := False;
In Value Entry Table - OnAfterGetRecord
IF FirstTime = False THEN BEGIN
incounter := incounter + 1;
FirstTime := True;
END;0 -
Hi Chi, your understanding is right and thank you for your response! But I aslo need to filter salesperson as well in the customer table, and then filter the date in the value entry table.
I added intcounter in the value entry groupfooter and footer sections and per your instructions, I added the codes, but it doesn't work. Please advise! Thank you very much!0 -
Hi Chi. I fixed something and it is now working. Thank you very much!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