For some reason, my code is working perfectly in my dev environment, but when uploading to live server - I got no error, just a "request timed out".
Local dev is server 2008 IIS7 - live server is 2003 IIS6
Code:
Dim filename As String = "c:\pdfTest\blank.pdf"
Dim document As PdfDocument = PdfReader.Open(filename)
document.Options.ColorMode = PdfColorMode.Cmyk
document.Info.Title = "Created with PDFsharp"
Dim page As PdfPage = document.Pages(0)
Dim gfx As XGraphics = XGraphics.FromPdfPage(page)
Dim Image As XImage = XImage.FromFile("c:\pdfTest\test.jpg")
gfx.DrawImage(Image, 100, 100, 200, 200)
document.Save("c:\pdfTest\output.pdf")
If I comment out the gfx.DrawImage(Image, 100, 100, 200, 2) then it opens the pdf and resaves it fine, so I know the problem is with the drawImage. The problem is, because no error is being returned, I dont know where to fix.
Please can someone help, as I need to get this live before the end of the week.
Many thanks in advance.