Is it possible to create and Advanced HTML /PDF te...
# advancedpdf
f
Is it possible to create and Advanced HTML /PDF template for the project record ?
t
You should be able to load the Help Center article that shows all available SuiteBuilder Advanced Templates with this URL: https://system.netsuite.com/app/help/helpcenter.nl?fid=SBADVTemplates.html
Based on this, it seems like you can't do that directly. But you might be able to write a SuiteScript that generates a PDF using a custom button instead!
☝️ 2
f
Got it thanks alot. Yeah just from my understanding that would be a saved search template which only limits 10 fields.
t
that would be a saved search template which only limits 10 fields
Could you clarify this part? Are you concerned that you won't be able to use SuiteScript to generate a PDF of the Project record type because of a limitation of the number of fields that you can pull into the PDF that gets generated?
f
According to netsuite, thier is a way of creating Advanced PDF /HTML template via saved search image below. Im not quite sure how I would get all the data from a suitescript and post it into the Advanced HTML template.
t
Here is an article explaining how to use SuiteScript to apply advanced templates to non-transaction records (since a "Project" is not a transaction): https://system.netsuite.com/app/help/helpcenter.nl?fid=section_4259402776.html
👍 1
f
Thanks so much for the help
❤️ 1
f
You can pretty much do whatever you can imagine with the Render tag in terms of creating PDFs. Once you have an object created, you can add multiple objects to it and then reference that output in your template.
Copy code
var documentRenderer = render.create();
documentRenderer.templateContent = myTemplateFile.getContents();
documentRenderer.addCustomDataSource({
     format: render.DataSource.OBJECT,
     alias: "snazzyobject",
     data: myJsonObject
});
documentRenderer.addRecord('myRecord', myRecord);
❤️ 2
m
@FAgudelo I’ve made a saved search PDF template that replicated a pick list and also a work order traveler. This went way beyond a ten field limit so I imagine a saved search template would be able to solve your issue fairly easily
Also redid the consolidated customer statement which displayed past due invoices and credit memos segmented by subsidiary so each subsidiary was its own section with its related transactions (up to 10 subs possible). So this saved search PDF is quite flexible and could probably handle your requirement
f
Thanks guys I've managed to solve it. needed 3 scripts and an hml template