PDFsharp & MigraDoc Foundation

PDFsharp - A .NET library for processing PDF & MigraDoc Foundation - Creating documents on the fly
It is currently Fri May 03, 2024 4:03 am

All times are UTC


Forum rules


Please read this before posting on this forum: Forum Rules



Post new topic Reply to topic  [ 2 posts ] 
Author Message
PostPosted: Fri Sep 25, 2009 6:00 pm 
Offline

Joined: Thu Sep 24, 2009 10:10 pm
Posts: 1
Hi. First I would like thank everyone involved for their work on this project. It made my life much easier when I was given a a large project with a ridiculously short time line and an unknown in the project was writing information out to a PDF.

I am using PDFsharp, WPF build and V1.3.

So my situation is that I take an existing PDF, I open it and write a jpg image over one of the pages and close it. This process works great in development and when deployed on IIS6 and Windows Server 2003. When I deploy it on Windows Server 2008 Web Edition SP1 it works 95% of the time. The other 5% I get the exception pasted at the end of this post.

I have searched and the only reference I can find to anything like this is here.

One of the comments has this piece of information but I cannot find any other information on it.
Quote:
Melinda M, Employee, replied 21 days ago
...
This looks like a bug I've seen in the Windows Imaging Component - it's fixed in Windows 7, but not yet in Server 2008.

There should be a patch coming out for Server 2008 soon, but it's not available yet. I know this is annoying, because I've run up against it myself a bunch!


That comment makes it sound like a Windows problem. Have any of you had any experience with this error? or any thoughts on what I might be able to do to work around it with your library to make this process run at five nines?

Thanks for your input.


Exception: COMException
Message: Catastrophic failure (Exception from HRESULT: 0x8000FFFF (E_UNEXPECTED))
Source: WindowsBase
TargetSite Name: MapUrlToZone

Stack Trace:
at MS.Win32.UnsafeNativeMethods.IInternetSecurityManager.MapUrlToZone(String pwszUrl, Int32& pdwZone, Int32 dwFlags)
at MS.Internal.PresentationCore.SecurityHelper.MapUrlToZoneWrapper(Uri uri)
at System.Windows.Media.Imaging.BitmapDecoder.SetupDecoderFromUriOrStream(Uri uri, Stream stream, BitmapCacheOption cacheOption, Guid& clsId, Boolean& isOriginalWritable, Stream& uriStream, UnmanagedMemoryStream& unmanagedMemoryStream, SafeFileHandle& safeFilehandle)
at System.Windows.Media.Imaging.BitmapDecoder.CreateFromUriOrStream(Uri baseUri, Uri uri, Stream stream, BitmapCreateOptions createOptions, BitmapCacheOption cacheOption, RequestCachePolicy uriCachePolicy, Boolean insertInDecoderCache)
at System.Windows.Media.Imaging.BitmapImage.FinalizeCreation()
at System.Windows.Media.Imaging.BitmapImage.EndInit()
at System.Windows.Media.Imaging.BitmapImage..ctor(Uri uriSource, RequestCachePolicy uriCachePolicy)
at System.Windows.Media.Imaging.BitmapImage..ctor(Uri uriSource)
at PdfSharp.Drawing.XImage..ctor(String path)
at PdfSharp.Drawing.XImage.FromFile(String path)


Top
 Profile  
Reply with quote  
PostPosted: Tue Jun 08, 2010 10:11 am 
Offline

Joined: Tue Jun 08, 2010 10:08 am
Posts: 1
Hi,

I don't know if you still have the problem, but I had the problem because of a lock on the image file. After unlocking the file, the problem was solved.

Success,
Luuk


Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 2 posts ] 

All times are UTC


Who is online

Users browsing this forum: No registered users and 78 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
Privacy Policy, Data Protection Declaration, Impressum
Powered by phpBB® Forum Software © phpBB Group