To simplify an export of invoice data to our accounting package I want to fetch the various address fields stored against the customer record to custom fields on my Sales Invoice doc type. I’ve setup a Sales Invoice custom field with the same name of “address_line1” and created a custom script for Sales Invoice of:
Will that work though @rmehta given the customer doc type doesn’t hold the address? When fetching the phone field from Address doc type in a custom print I’ve used this successfully:
So that was what I was based my logic above on. I need to lookup to Address doc type which is linked to customer doc type and fetch the address_line1, etc. Does that make sense?
Your statement assumes address details are against Customer doc type when they aren’t?
I tried your statement with both read only on and off on my Sales Invoice “Address_line1” field and it didn’t work unfortunately.