Word Templates As Email Body
Miklos_Hollender
Member Posts: 1,629
This is a nice feature because we can bring inside Navision the invoice e-mailing which we did formerly with an external tool. The issue is that the cover letter, the body of the email is for us just a long narrative text, nicely formatted, no database fields, just stuff like dear customer thank you for buying blah blah blah warranty blah blah we love you blah blah end. But I need it in two languages, so I cannot just type it as a fixed text in the Word template.
Creating a separate ML TextConstant for every section looks weird, and how do I even add the formatting? If I have a link in the middle of a long section, I create the text up to it as one text constant, the link as a second and the rest as a third one?
I would much rather write it directly in Word, but in that case I need to link a separate layout per language somehow.
Hmmm... one possibility would be customizing the Table77 GetEmailBody function that if the layout name ends with an _ like INVMAIL_ then it automatically goes looking for INVMAIL_ENU INVMAIL_DEU layouts depending on the report language...
Creating a separate ML TextConstant for every section looks weird, and how do I even add the formatting? If I have a link in the middle of a long section, I create the text up to it as one text constant, the link as a second and the rest as a third one?
I would much rather write it directly in Word, but in that case I need to link a separate layout per language somehow.
Hmmm... one possibility would be customizing the Table77 GetEmailBody function that if the layout name ends with an _ like INVMAIL_ then it automatically goes looking for INVMAIL_ENU INVMAIL_DEU layouts depending on the report language...
0
Best Answer
-
You can have a look at the solution I made for a customer.
I share it here https://juhl.blog/2017/11/05/making-body-in-document-mailing-multilingual/Follow me on my blog juhl.blog5
Answers
-
How about using Interactions instead? The standard code around it is a bag of ..., but if you do your coding smartly, it can be really a great tool.
I have build a solution, where on the interaction template you can define a codeunit number, which is then called to prepare both header and data in some buffer table, and then interaction template is populated from that buffer table, rather from a hardcoded set of fields.Slawek Guzek - www.yitron.co.uk
Business Central, MS SQL Server, Wherescape RED;0 -
You can have a look at the solution I made for a customer.
I share it here https://juhl.blog/2017/11/05/making-body-in-document-mailing-multilingual/Follow me on my blog juhl.blog5 -
You can have a look at the solution I made for a customer.
I share it here https://juhl.blog/2017/11/05/making-body-in-document-mailing-multilingual/
Well of course that would not work if they change the language on the sales order instead of entering it on the customer card, but otherwise very fine solution. I could probably live with telling people to always enter it on the customer card and don't do it on the fly.
Heh, one of the Solution Centers we use typically sends me quotes in German but if it is a bigger project I request it in English to show it to my boss, so there isa legit business case for on the fly changing, but anyway
0
Categories
- All Categories
- 75 General
- 75 Announcements
- 66.7K Microsoft Dynamics NAV
- 18.8K NAV Three Tier
- 38.4K NAV/Navision Classic Client
- 3.6K Navision Attain
- 2.4K Navision Financials
- 116 Navision DOS
- 851 Navision e-Commerce
- 1K NAV Tips & Tricks
- 772 NAV Dutch speaking only
- 610 NAV Courses, Exams & Certification
- 2K Microsoft Dynamics-Other
- 1.5K Dynamics AX
- 253 Dynamics CRM
- 103 Dynamics GP
- 6 Dynamics SL
- 1.5K Other
- 991 SQL General
- 383 SQL Performance
- 34 SQL Tips & Tricks
- 28 Design Patterns (General & Best Practices)
- Architectural Patterns
- 9 Design Patterns
- 4 Implementation Patterns
- 53 3rd Party Products, Services & Events
- 1.6K General
- 1K General Chat
- 1.6K Website
- 77 Testing
- 1.2K Download section
- 23 How Tos section
- 249 Feedback
- 12 NAV TechDays 2013 Sessions
- 13 NAV TechDays 2012 Sessions
