Discussions
Stay up-to-date with the latest news from NetSuite. You’ll be in the know about how to connect with peers and take your business to new heights at our virtual, in-person, on demand events, and much more.
Now is the time to ask your NetSuite-savvy friends and colleagues to join the NetSuite Support Community! Refer now! Click here to watch and learn more!
How to Render Module - mergeEmail function erroring
I am getting this error: {"type":"error.SuiteScriptError","name":"WRONG_PARAMETER_TYPE","message":"Wrong parameter type: options.entity is expected as object. " when attempting to use the render.mergeEmail() function.
My code:
var email_merger = render.mergeEmail({
templateId : 13,
entity : {
type : params.type,
id : params.id
},
customRecord : {
type : 'customrecordnickname',
id : customer.getValue({ fieldId: 'custentitymktreconinq' })
}
});
I am not sure why I am getting this error as entity is being given an object.
0