PDA

View Full Version : ERROR: Cannot activate MSHtml engine while creating ABCPdf.net 8.0


sbkrishnan25
08-05-2011, 01:39 AM
Hi

Please help me

I am in the process of creating html to pdf using ABCPdf.net 8.0.

It is working fine in my local machine, but it is not working in server it through s error like "Cannot activate MSHtml engine. Please refer to documentation for more information. "

This is my code

Doc theDoc = new Doc();
int docid = 0;
theDoc.Rect.Inset(15, 10);
docid = theDoc.AddImageUrl(GetASBaseUrl() + "HTMLFiles/" + filename + ".htm");
while (true)
{
theDoc.FrameRect();
if (!theDoc.Chainable(docid))
break;
theDoc.Page = theDoc.AddPage();
docid = theDoc.AddImageToChain(docid);
}
string pdfFilename = System.Guid.NewGuid().ToString() + ".pdf";
theDoc.Save(Server.MapPath("~/PDFFiles/" + pdfFilename));

bruce
08-05-2011, 10:27 AM
This is not supported.

sbkrishnan25
08-06-2011, 05:56 AM
Hi


Finally i solved the Error,
This is the issue of the IIS setting

IN the IIS Application pool ==> Select the application go to advance setting ==>Property Load user profile = true;

I have modified the setting and resolved the error.

Thanks