40 character limitation on mail merge field name

When adding a csv as the field list source but using a dataset with aspose as the data source for a mail merge, is there a way to exceed 40 characters in the field name with in Word? Every field that has a name longer than 40 characters is truncated to 40.

Hi Jason,

Thanks for your inquiry. The mail merge field name's length limit is 255. However, mail merge field's display text is 40 characters. Please open your input document in MS Word and press Alt + F9 to see the complete mail merge field name.

Please read following link for your kind reference.
Word mail merge field size limitation

I tried that. The results are as follows:

Mail merge field manulally created could exceed 40 characters.
{ MERGEFIELD 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890 }

Mail merge field imported by list could NOT exceed 40 characters.
{ MERGEFIELD M_12345678901234567890123456789012345678 }

We need to be able to exceed 40 while importing from an existing list as we have many hundreds of selectable fields.

Hi Jason,

Thanks for your inquiry.
jmallory0001:

Mail merge field imported by list could NOT exceed 40 characters.
{ MERGEFIELD M_12345678901234567890123456789012345678 }

We need to be able to exceed 40 while importing from an existing list as we have many hundreds of selectable fields.
Could you please share some detail what exact you want to achieve using Aspose.Words? Are you creating mail merge fields using Aspose.Words?

Please attach the following resources here for testing:

  • Your input Word document.
  • Please attach the output Word file that shows the undesired behavior.
  • Please create a standalone console application (source code without compilation errors) that helps us to reproduce your problem on our end and attach it here for testing.

As soon as you get these pieces of information ready, we'll start investigation into your issue and provide you more information. Thanks for your cooperation.

PS: To attach these resources, please zip them and Click 'Reply' button that will bring you to the 'reply page' and there at the bottom you can include any attachments with that post by clicking the 'Add/Update' button.