Docx From Dynamic Template

Hi,

I Have a requirement of Generating a dynamic word Document using cdt which is of multiple type. But when I am trying to generate the document using the smart service Docx From Dynamic Template all the values in cdt is appearing in a single row. can u please help me how to solve this issue.

Thanks in advance

OriginalPostID-261043



  Discussion posts and replies are publicly visible

Parents
  • 0
    Certified Lead Developer
    Hi Krishna Prasad,

    I mentioned the necessary steps for generating DOCX from Dynamic Template in Steps to generate template.txt and attaching the base template and generated docx for your reference.
    Please let me know if this helped you.

    Steps to generate template.txt

    adtDocxTemplate.docx

    New Document.docx

  • 0
    Certified Lead Developer
    in reply to Ram

    Hi Ram,

    I was able to generate the document dynamically.

    However, if I want to add a new column in the template, it behaves as if it is adding but when run it tries to pull the value from another column and display here.

    Eg:- The columns in the template are name, dob, address

    I want to add a new column called "interest". 

    I opened the template and copy one of the columns and rename d.@dob (or) d.@address to d.@interest.

    When I run the template, interest is always replaced with value of dob (or) address (from where it is copied)

    I tried multiple ways but not able to avoid it.

    Should we add a column in a specific way to the template? Please suggest.

  • Hi Phanibabu,

                           Since you had copied and create this interest column, the field will refer the actual column from where it was copied. Please follow the below steps to change the field reference in the template.

    1. Right Click on the new field(d.@interest) which you had created and click on edit field.

    2.Change the Field name under the Field Properties tab to ${d.@interest} and Click on OK.

    Update the new template in Appian and try, the new field value should refer to correct data .

    Thanks,

    Vadivelan

Reply
  • Hi Phanibabu,

                           Since you had copied and create this interest column, the field will refer the actual column from where it was copied. Please follow the below steps to change the field reference in the template.

    1. Right Click on the new field(d.@interest) which you had created and click on edit field.

    2.Change the Field name under the Field Properties tab to ${d.@interest} and Click on OK.

    Update the new template in Appian and try, the new field value should refer to correct data .

    Thanks,

    Vadivelan

Children
No Data