Hi,
Can anyone help how to split the pdf for the different customer account to send email to same customer.
Currently , It is generating single pdf with all customer report and sending to the last customer in the loop.
Does anyone help me with the new logic of how to create pdf and send separately to the selected customer.
Current Code in Fetch method-
element.printJobSettings().Format(printformat::PDF);
element.setTarget(PrintMedium::Mail);
element.printJobSettings().preferredTarget(PrintMedium::Mail);
element.printJobSettings().preferredFileFormat(Printformat::PDF);
element.printJobSettings().preferredMailFormat(printformat::PDF);
while (partyRun.next())
{
partyCust = partyRun.get(tablenum(CustTable));
custTable = partyRun.get(tablenum(CustTable));
element.printJobSettings().mailTo(custTable.Email);
this.processPartyId(partyCust.PartyId, selectedCompanyList);
}
this.cleanUp();
}
return true;