Steve Reeder
Steve Reeder

Reputation: 1022

Netsuite Advanced PDF - Display Country Name instead of Country Code

I have an Advanced PDF where I want to split the Billing Address into it's components, however when I use ${record.billcountry} I get "AU" instead of "Australia".

What is the method to display the Country name instead of the ISO code?

Upvotes: 2

Views: 1690

Answers (3)

Joan Pijuan
Joan Pijuan

Reputation: 1

This worked for me:

${record.entity.billcountry}

Upvotes: 0

Krypton
Krypton

Reputation: 5276

Here's a horrible hack, based on the assumption that the country is always the last line of the address:

${record.billaddress?keep_after_last(">")}

It doesn't seem too easy to access the countries list to match the short names (the ISO code) to the full names from within the templates, but this works even if it looks horrid. The > is of course just the last character of the html line break <br /> which is in the address text, as passed to the template, between each line.

Upvotes: 2

Rusty Shackles
Rusty Shackles

Reputation: 2840

Have you tried ${record.billcountry@text}?

Upvotes: 0

Related Questions