Report like yellow pages

LeoNav
Member Posts: 55
Hi, 
I'm working on reports on Navision 5.0 SP1.
I have created a report that works very well. It's a contacts list. I would like to show two columns per page just like the yellow pages. You see what I mean. But I don't know how to set it up.
Thanks

I'm working on reports on Navision 5.0 SP1.
I have created a report that works very well. It's a contacts list. I would like to show two columns per page just like the yellow pages. You see what I mean. But I don't know how to set it up.
Thanks

0
Comments
-
Create a new report using the wizard. Select Label-Type Report Wizard.
Take a look at the code and sections the wizard has created.
Try to do the same on your report.0 -
Ok thanks.0
-
I have an other question. For the moment the recors are sorted by name but from left to right etc.
exemple :
PAGE 1
record 1 record 2
record 3 record 4
PAGE 2
record 5 record 6
record 7 record 8
How can I have it like this (juste like yellow pages) :
PAGE 1
record 1 record 3
record 2 record 4
PAGE 2
record 5 record 7
record 6 record 80 -
Yes, this is possible. We just did this for one of our customers.
This is what we did.
We created an array for each field that needed to be printed in the section.
These arrays were very large, we used an arraysize of 9000.
Then we filled the array by reading the table for all records within the filterset.
What you will have to figure out is how many lines you can print on a page. And you need to keep track of how many lines you have printed, how many lines you need for 1 record and how many complete records will fit in 1 column on your page.
We then created an integer and printed the array using the "Number" variable from the integer table.
The range for your number will be SETRANGE(Number,1,ROUND((rec.Count / 2),1,'>')).
For your first column you can read the array with the Number variable as the Index. For the second column you add the Maximum number of records to print per page to the index. So if you can print let's say 63 lines on the page and you need 3 lines for the header and 4 lines for each record plus 1 spacer line, the number of records you can print will be (63 -3)/(4 + 1) = 60/5 = 12. So the index for the arrays in the second column will be (Number + 12).
When you go to the next page, make sure that you have added an additional number of records per page to the Number variable to compensate for the second column, in this example it would be 12.
This all works, but it does get tricky at times. We had variable headings and sections prior to the section that needed to be printed this way. If you only print 1 dataitem then it might be an option to force a new page everytime you reach a multiple of the maximum number of complete records per page. This to prevent that records are split over 2 pages.
Let me know if this pointed you in the right direction.
Regards,
WillyFostering a homeless, abused child is the hardest yet most rewarding thing I have ever done.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