How can I terminate loop, When I got my condition(Quotation number ) in sales order items child table

SO PRINT FORMAT

Hello all, I’ve created Sales Order against Quotation now I want to show Quotation number only one time on my Sales Order Custom Print format, So please give me suggestions to how can I terminate loop when I got my condition (Quotation Number).

For more details please find the attached both images now here Quotation number is multiple time printed on print format,which means my loop is not closed after my condition executed.

Thanks & Regards,
Parmeshwar Kadam
-9764131517
-Parmeshwark@gmail.com