When printing invoices, credit memos, or other transaction forms in NetSuite, users may notice that the company logo, name, or address does not appear on the document. This can occur depending on how the form is configured or based on available data for the subsidiary or company record.
This issue is often due to missing or restricted access to the subsidiary or company information fields in the Advanced PDF/HTML template. If the data isn’t available or if the fields are left blank, the header section may appear incomplete or missing entirely.
Solution: Add Logic in the Template
Use the following code snippet to ensure that a logo and address are displayed even if some fields are unavailable:
<td rowspan="3">
<#if subsidiary.logoUrl?length != 0>
${subsidiary.logo}
<#else>
<img src="${companyInformation.logoUrl}"/>
</#if>
</td><td rowspan="3">
<strong><span style="font-size: 12px;">${subsidiary.name}</span></strong><br/>
<span style="font-size: 10px;">${subsidiary.custrecord_company_brn}</span><br/>
<span style="font-size: 12px;">${subsidiary.mainaddress_text}</span>
</td>
Disclaimer
The sample code described herein is provided on an "as is" basis, without warranty of any kind, to the fullest extent permitted by law. Oracle + NetSuite Inc. does not warrant or guarantee the individual success developers may have in implementing the sample code on their development platforms or in using their own Web server configurations. Oracle + NetSuite Inc. does not warrant, guarantee or make any representations regarding the use, results of use, accuracy, timeliness or completeness of any data or information relating to the sample code. Oracle + NetSuite Inc. disclaims all warranties, express or implied, and in particular, disclaims all warranties of merchantability, fitness for a particular purpose, and warranties related to the code, or any service or software related thereto. Oracle + NetSuite Inc. shall not be liable for any direct, indirect or consequential damages or costs of any type arising out of any action taken by you or others related to the sample code.
By incorporating this logic, you can ensure your printed documents maintain a professional and consistent appearance, regardless of role restrictions or missing data. Happy customizing!