Hi I’m wondering is there anyway I can print Packi...
# suitescript
l
Hi I’m wondering is there anyway I can print Packing Slip in Suitelet without using 
render.packingSlip
 ? I’ve try following code but the result is mismatch with 
render.packingSlip
Copy code
const itemFulfillment = record.load({ type: 'itemfulfillment', id: 123});
const salesOrder = record.load({ type: 'salesorder', id: 456 });
const templateRenderer = render.create();
templateRenderer.setTemplateByScriptId({
    scriptId: "CUSTTMPL_PACKING_SLIP"
});
templateRenderer.addRecord({
    templateName: 'record',
    record: itemFulfillment
});
templateRenderer.addRecord({
    templateName: 'salesorder',
    record: salesOrder
});
const xml = templateRenderer.renderAsString()
response.renderPdf({
    xmlString: xml,
})
n
What do you mean "the result is a mismatch"? You mean that the output from your script does not match the output from recnder.packingSlip?
l
@NElliott that’s correct, some field is not showing correctly. I figure out the difference and create another Adv. PDF template instead of using the same as Render.packingSlip