Add HTML to Suitelet form

To add HTML to your Suitelet form, use Form.addField(options) to add a field to the form. Specify the field type as INLINEHTML and use the Field.defaultValue property to set the HTML value.

var htmlImage = form.addField({
                    id: 'custpage_htmlfield',
                    type: serverWidget.FieldType.INLINEHTML,
                    label: 'HTML Image'
                });
htmlImage.defaultValue = "<img src='https://<accountID>.app.netsuite.com/images/logos/netsuite-oracle.svg' alt='NetSuite-Oracle logo'>"

Leave a comment

Your email address will not be published. Required fields are marked *