在 PDFCreator 中锁定 pdf
我希望有人曾经使用过 PDFCreator。
我正在 .NET 中使用 PDFcreator 来自动化我们的 PDFing 机制。
除了安全选项之外,一切似乎都运行良好。
尽管如此,我已经设置了 UsePDFSecurity = 1;并且 PDFDisallowPrinting= 1;打印按钮 仍然可用。但是,如果我在从 Word 打印时使用 PDFCreator 程序并选择 UseSecurity 和 DisallowPrinting,则生成的 pdf 上的打印按钮将被禁用。显然我在代码中遗漏了一些东西,因为它正常工作。
以前有人用过这个功能吗?
I hope there are someone who have used PDFCreator before.
I am using PDFcreator in .NET to automate our PDFing mechanism.
All seems to be working fine apart from the security options.
Even though, I have set the UsePDFSecurity = 1; and PDFDisallowPrinting= 1; the print button
still available. However, if I use the PDFCreator program when prnting from word and select UseSecurity, and DisallowPrinting, the print button is disabled on the generated pdf. Clearly I am missing something in the code as it is normally working.
Has anyone used this feature before?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
我已经找到了我想的答案;除了 PDFUseSecurity 属性之外,PDFOwnerPass 和
PDFOwnerPasswordString 属性也应该设置。
PDFUseSecurity = 1;
PDF所有者通行证 = 1;
PDFOwnerPasswordString = "密码";
这将为用户提供成功设置其他安全属性的功能,例如 DisasslowPrinting、DisallowCopyig 等,
我只是想移植答案,因为其他人可能需要这样做。
干杯
梅苏特
I have found the answer I think; In addition to PDFUseSecurity property, the PDFOwnerPass and
PDFOwnerPasswordString properties should be set too.
PDFUseSecurity = 1;
PDFOwnerPass = 1;
PDFOwnerPasswordString = "Password";
this will provide user to set other security properties successfully such as DisasslowPrinting, DisallowCopyig and so on
I just wanted to port the answer as someone else may need that.
Cheers
Mesut