The following sample shows how to render a transaction record into an HTML page.
/**
* @NApiVersion 2.x
*/
require([‘N/render’],
function(render) {
function renderTransactionToHtml() {
var transactionFile = render.transaction({
entityId: 23,
printMode: render.PrintMode.HTML
});
}
renderTransactionToHtml();
});
Note: The entityId value in this sample is a placeholder. Before using this sample, replace the placeholder values with valid values from your NetSuite account