We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy.
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Using If-Then-Else statement in a document template

Thread ID:

Created:

Updated:

Platform:

Replies:

93880 Apr 9,2010 09:37 AM UTC Apr 14,2010 12:09 PM UTC ASP.NET Web Forms (Classic) 3
loading
Tags: DocIO
eric menglier
Asked On April 9, 2010 09:37 AM UTC

Hi,

I would like to know if it is possible to mailmerge document template that contains formula and rules like IF THEN ELSE statement.

For example,
I have created a .docx document template with the following rule :
{ IF {MERGEFIELD SEX } = "MALE" "Hello Mister" "Hello Miss" }

I have created the document with a csv file that contains the following field names and values :
"SEX";"NAME";"ADRESS"
"MALE";"John";"Paris"

Thanks



template_d8beb69c.zip

Poornima R [Syncfusion]
Replied On April 13, 2010 12:56 PM UTC

Hi eric,

Thank you for your interest in syncfusion products.

Essential DocIO supports updation of If-Then-Else field within the document. Conditional checking is not performed by DocIO.To check the condition and update the field press F9 in the generated document.

Field name and Field values from the csv file can be obtained using XlsIO. We have prepared the sample for your requirement. Could you please find the sample from the below link. Try running the sample and let us know if this helps.

Sample:
http://www.syncfusion.com/uploads/redirect.aspx?&team=support&file=F93880-314068990.zip

Please let us know if you have any queries.

Regards,
Poornima

eric menglier
Replied On April 14, 2010 08:21 AM UTC

Hi,
Thank you for your help.
I tried running the sample and it worked. The problem was that I used a .docx template.

In case of a .doc template, Essential DocIO correctly performs the updation of If-Then-Else field.
Otherwise, if I use a .docx template, the updation of If-Then-Else field does not work.

Regards


Poornima R [Syncfusion]
Replied On April 14, 2010 12:09 PM UTC

Hi Eric,

Thank you for your update.

We were able to reproduce the mentioned issue.We suspect this could be a defect.We have forwarded this issue to our development team for further analysis.

Could you please report this issue through Direct Trac Developer Support System https://www.syncfusion.com/account/login?ReturnUrl=%2fsupport%2fdirecttrac%2fincidents because you can take the advantage of the expertise of a dedicated support engineer and a guaranteed response time and we hope you will take advantage of this system as well. If you have already reported through Direct trac, please ignore this.

Please let us know if you have any queries.

Regards,
Poornima

CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon

;