Announcements
Dear NAV Peers,
I'm developing a production order report , In the report i have used 1) Production order and 2) production order line table .I have a field as specification where i want to fetch the value through coding.
The below coding i have written in production order line -> OnAfterGet record ()
RecItem.RESET;
RecItem.SETRANGE(RecItem."No.","Prod. Order Line"."Item No.");
IF RecItem.FINDSET THEN BEGIN
RTestPlanSetup.RESET;
RTestPlanSetup.SETRANGE (RTestPlanSetup."Item No.",RItem."No.");
IF RTestPlanSetup. FINDSET THEN BEGIN
RTestPlan.RESET;
RTestPlan.SETRANGE(RTestPlan."No.",RTestPlanSetup."Test Plan No.");
IF RTestPlan.FINDSET THEN BEGIN
RTestPlanPropertySet.RESET;
RTestPlanPropertySet.SETRANGE(RTestPlanPropertySet."Test Plan No.",RTestPlan."No.");
RTestPlanPropertySet.SETRANGE(RTestPlanPropertySet.Version,RTestPlan.Version);
IF RTestPlanPropertySet.FINDSET THEN BEGIN
REPEAT // new
NewSpecification := RTestPlanPropertySet.Description;
MESSAGE('%1',NewSpecification);
UNTIL RTestPlanPropertySet.NEXT =0;
// MESSAGE('%1',NewSpecification);
END;
END;
END;
END;
in the test plan property we have 5 lines , in the message box all the five lines are displayed but in layout it display the last line only . Please help .
the below image is the report , only the last line is being displayed.
Looking forward for the solution for the same . Thanks in advance.
Instead of VRCRLF use <br\> and use that in place holder and mark it as HTML. Please check this for example
blogs.catapultsystems.com/.../add-html-formatting-to-your-sql-server-reporting-services-ssrs-reports
Hi,
Instead of giving BinCount<5 as mentioned in the link which i mentioned above, you will need to declare an integer variable say 'n' which will count the no of production order lines after getting the current record using setrange. You need to code for this.
Now you need to change the code mentioned in the link to the below:
If BinCount<n then begin
//same as the link
end;
Dear tina, thanks for your reply , i just saw ur link of splitting in the lines, Actually in my report we can't define the fixed length of the description . It varies for each and test plan no . So friends plz help me how to proceed with this.
Hi Cindrella,
You can check the below link to split a concatenated string on a new line.
https://www.dynamics101.com/nav-2013-r2-report-trick-split-concatenated-string-on-new-line/
Dear Suresh,
i tried the above step too, i get the with vbcrlf in the report also and its not getting displayed as required . :( as 2 specification together as a paragraph.
Please add the line break VBCRLF before adding each line in the code and that should give a line break.
NewSpecification := RTestPlanPropertySet.Description + 'VBCRLF';
Check if this does the trick
hi mahesh , if you look the image its displyed together as a paragraph. I want one in a line.
Do you mean to display all the specification lines?
Dear Suresh,
Can you please help for the issue posted earlier. I would really appreciate you if you can help me to find a solution.
thank you so much .. is it possible to get one specification per line. Now it displays as the below
Stay up to date on forum activity by subscribing. You can also customize your in-app and email Notification settings across all subscriptions.
André Arnaud de Cal... 290,186 Super User 2024 Season 2
Martin Dráb 227,996 Super User 2024 Season 2
nmaenpaa 101,148