PDFsharp & MigraDoc Foundation

PDFsharp - A .NET library for processing PDF & MigraDoc Foundation - Creating documents on the fly
It is currently Sat Jun 15, 2024 7:57 pm

All times are UTC


Forum rules


Please read this before posting on this forum: Forum Rules



Post new topic Reply to topic  [ 4 posts ] 
Author Message
PostPosted: Thu Oct 30, 2008 8:13 am 
Offline

Joined: Thu Oct 30, 2008 7:56 am
Posts: 2
Hi, I got to know this great PDF library when researching online. I had a situation here. I am quite new to this APIs.

I have 1 folder where the files are dynamically download from the source server. Lets make an assumption, there are 10 PDFs files in this folder (non protected).

I need to transfer this files across the wire. So I need to protect these 10 files with a secret key or password. Then over the destination, I like to unprotect these documents back to the actual documents.

Can I actually do this in PDFSharp? Any snippets to make this happen?

I saw the protect sample code. But it doesn't meet my needs here. Any help?

Thanks.


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Thu Oct 30, 2008 9:48 am 
Offline
PDFsharp Guru
User avatar

Joined: Mon Oct 16, 2006 8:16 am
Posts: 3100
Location: Cologne, Germany
Hi!
I'm not sure what you exactly want.

There's a protect sample that adds a password.
There's an unprotect sample that removes the password.
Both change the password that prevents editing. Files are still viewable.

You can also set a password to prevent viewing - Adobe Reader prompts for the password before showing the file. Is that what you want?

You can also store the PDF files in a password protected archive (ZIP, RAR, ...).

_________________
Regards
Thomas Hoevel
PDFsharp Team


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Thu Oct 30, 2008 12:14 pm 
Offline

Joined: Thu Oct 30, 2008 7:56 am
Posts: 2
Thanks for the response.

Basically, I have 10 existing PDF documents (all un-protected without any password). Can I use C# programmatically protect/unprotect these files using PDFSharp?

Hope you understand.

Any help?


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Thu Oct 30, 2008 12:17 pm 
Offline
PDFsharp Guru
User avatar

Joined: Mon Oct 16, 2006 8:16 am
Posts: 3100
Location: Cologne, Germany
Look at the ProtectDocument and UnprotectDocument samples.

_________________
Regards
Thomas Hoevel
PDFsharp Team


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

All times are UTC


Who is online

Users browsing this forum: No registered users and 159 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:  
Privacy Policy, Data Protection Declaration, Impressum
Powered by phpBB® Forum Software © phpBB Group