web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Microsoft Dynamics NAV (Archived)

No Copies not working properly in report

(0) ShareShare
ReportReport
Posted on by

Hi everyone, I'm trying to create a shipment order but when I put 2 in my Number of Copies the report only prints one page.. and must have 3 pages understand?

So I have in Request Page

Expanded Type SubType SourceExpr Name Caption
0 Field NoOfCopies <Control1> N.º Cópias

And in my Code:

CopyLoop - OnPreDataItem()
NoOfLoops := 1 + ABS(NoOfCopies);
CopyText := '';
SETRANGE(Number,1,NoOfLoops);
OutputNo := 1;

CopyLoop - OnAfterGetRecord()
IF Number > 1 THEN BEGIN
CopyText := Text001;
OutputNo += 1;
END;
CurrReport.PAGENO := 1;
TotalQty := 0; // Item Tracking

CopyLoop - OnPostDataItem()


PageLoop - OnPreDataItem()
// Item Tracking:
IF ShowLotSN THEN BEGIN
TrackingSpecCount := 0;
OldRefNo := 0;
ShowGroup := FALSE;
END;

PageLoop - OnAfterGetRecord()

PageLoop - OnPostDataItem()

I cant figure what I need to do more.. Anyone can help?

5700.final.png

*This post is locked for comments

I have the same question (0)
  • Suggested answer
    Suresh Kulla Profile Picture
    50,247 Super User 2025 Season 2 on at

    Is this a standard report or a new or customized report ?

  • Suggested answer
    Alexander Ermakov Profile Picture
    28,096 on at

    Can you just look at a standard similar report and copy the code from there?

  • Community Member Profile Picture
    on at

    This is a report created by myself

  • Community Member Profile Picture
    on at

    Already done that, I'm using the code of the report 208 (Sales Shipment)

  • Community Member Profile Picture
    on at

    Anyone can help? My report layout have in the list a group by the key No_Sales Header and by the Output no


  • Marcellus Profile Picture
    2,735 on at

    Hi Catia,

    Please post a screenshot of how your dataset is structured, so we can check where you put the copyloop and how is your indentation done first.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

Leaderboard > 🔒一 Microsoft Dynamics NAV (Archived)

#1
HoangNam Profile Picture

HoangNam 7

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans