«TableStart:AgentRebate»
«SOURCE»
«TableEnd:AgentRebate»
Here i need to print like (if the source=test)
TEST
«TableStart:AgentRebate»
«SOURCE»
«TableEnd:AgentRebate»
Here i need to print like (if the source=test)
TEST
Hi Piers,
Thanks for your inquiry. In your case, you need to format your mail merge field with upper as shown below.
{ MERGEFIELD SOURCE * Upper * MERGEFORMAT }
If you still face problem, please share following detail for investigation purposes.
create a standalone/runnable simple application (for example a Console
Application Project) that demonstrates the code (Aspose.Words code) you used to generate
your output document
HI Tahir.manzoor
I have already created like this MERGEFIELD Source * Upper * MERGEFORMAT
i have uploaded my test template can you please see this once
Suresh@valuepro.com.au
Hi Piers,
Thanks for sharing the detail. Perhaps, you are using an older version of Aspose.Words; as with Aspose.Words v14.6.0, I am unable to reproduce this problem on my side.
I would suggest you please upgrade to the latest version of Aspose.Words i.e. v14.6.0 and let us know how it goes on your side. I hope, this will help. I have used the following code example to test this issue and have attached the output document with this post for your kind reference.
Document doc = new Document(MyDir + "test142.docx");
DataTable dt = new DataTable("AgentRebate");
dt.Columns.Add("Source", typeof(string));
dt.Rows.Add("Test Data");
doc.MailMerge.ExecuteWithRegions(dt);
doc.MailMerge.Execute(new string[] { "Staff.Name" }, new string[] { "Some text" });
doc.Save(MyDir + "Out.docx");