Hi,
I implemented a solution to send a report through e-mail but the report never gets sent if I choose to send in HTML40.
Curious about why the e-mail doesn't not get sent, I looked at the Crystal engine code and I found something curious.
Using the method Export(ExportOptions) of the class CrystalDecisions.CrystalReports.EngineReportDocument, it passes through the class CrystalDecisions.CrystalReports.Engine.FormatEngine, in the method Export(ExportRequestContext reqContext).
Looking at the method:
public virtual void Export(ExportRequestContext reqContext)
{
if ((reqContext.ExportInfo.ExportFormatType == ExportFormatType.HTML32) || (reqContext.ExportInfo.ExportFormatType == ExportFormatType.HTML40))
{
if ((reqContext.ExportInfo.ExportDestinationType != ExportDestinationType.MicrosoftMail) && (reqContext.ExportInfo.ExportDestinationType != ExportDestinationType.ExchangeFolder))
{
new HTMLExporter(this, reqContext).Export();
}
}
else
{
...
}
}
Since in the ExportFormatType I use HTML40, it enters in the first IF, but then I have the ExportDestinationType defined as MicrosoftMail and it does not enter the second if, ultimately not sending the e-mail.
Is it supposed to be like this?
I have Crystal Reports 2008 SR2 with FP 2.7 and .NET Framework 3.5 SP1 on a Windows Vista.
Thanks