在 SharePoint 中将动态变化的水印附加到 PDF

发布于 2024-08-27 21:16:30 字数 583 浏览 12 评论 0原文

这主要是一个可能性问题,而不是指令问题。我是一名编程顾问,为我的客户开发 WSS 项目站点系统。我们有一个文档库,上传文件后要经过复杂的审批流程。由于此过程中有多个阶段,我们有一个额外的字段来指示文档的当前状态。

现在,我的客户已经迷上了 PDF 水印的想法。他希望在文档(已经是 PDF)上贴上与当前状态相对应的水印,这样,随着审批过程的每个阶段,水印都会发生变化。

实现此目的的一种方法(PDF 水印的传统方法)是将文档的“干净”副本隐藏在网站上的某个位置,并从中创建一个在审批过程的每个阶段都带有水印的新 PDF。由于文件名永远不会改变,因此这个新的 PDF 可以不断上传到公共图书馆,始终覆盖旧版本并模拟“动态变化的水印”。然而,在各个阶段,也会有人上传带有更正和建议的干净副本,更不用说处理两个库的复杂性以及我们将存储的文件数量加倍的事实。我和我的客户都认为这不是一条可行的选择道路。

我们想要做的是能够“修改”PDF 中的水印,这样我们只需保留文件的一份副本。不幸的是,据我所知,在大多数情况下,当您制作水印之类的东西(其本质上应该是“不可修改的”)时,您以后将无法对其进行编辑。那么,是否有可能 PDF 的一部分无法被下载该文件的任何人更改,但可以作为工作流程或其他对象模型过程的一部分进行更改?

This is primarily a question of possibilities more than instructions. I'm a programming consultant working on a WSS project site system for my client. We have a document library in which files are uploaded to go through a complex approval process. With multiple stages in this process, we have an extra field which dictates what the current status of the document is.

Now, my client has become enamored with the idea of PDF watermarking. He wants the document (which is already a PDF) to be affixed with a watermark corresponding to the current status, such that with each stage of the approval process the watermark will change.

One method, the traditional method for PDF watermarking, of accomplishing this is to have one "clean" copy of the document somewhere hidden on the site, and create a new PDF from it that has the watermark at each stage of the approval process. Since the filename will never change, this new PDF can be uploaded continually to a public library, always overwriting the old version and simulating a "dynamically changing watermark". However, in the various stages there will also be people uploading clean copies with corrections and suggestions, nevermind the complex nature of juggling around two libraries and the fact we double the number of files stored. My client and I agree that this is not a practical path to choose.

What we would like to do is be able to "modify" the watermark in a PDF, so that we only have to keep one copy of the file. Unfortunately, from what I've seen, in most cases when you make something like a watermark, which in its nature is supposed to be "unmodifyable", you won't be able to edit it later. So, is it possible to have a part of a PDF which cannot be changed by anyone who downloads the file, but can be changed as part of a workflow or other object model process?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(4

丑疤怪 2024-09-03 21:16:30

您可以使用事件处理程序,以便每次签入文档时都会运行代码。在该代码中,您可以执行修复/检查,使水印成为您想要的样子。这假设您可以编写代码来操作 PDF 的内部结构,使其具有您想要的水印。

You could use Event Handlers such that code was run every time a document was checked in. In that code you could perform the fixup/check that made the watermark be what you wanted it to be. This assumes you can write code that manipulates a PDF's internal structure such that it has the watermark that you desire.

装迷糊 2024-09-03 21:16:30

在我看来,您希望允许人们修改他们下载的 PDF,但不能修改其水印。如果水印嵌入在 PDF 中(afaict),这可能几乎是不可能的,但如果水印图像位于 PDF 外部怎么办?是否可以在通过 HTTP 获取的 PDF 中嵌入水印?然后你可以嵌入:

<watermark image="http://sharepoint/site/_vti_bin/docstatus.asmx?id=5">

当然,我对 PDF 不了解,所以这可能不可能,但你明白了。

-奥辛

It sounds to me like you want to allow people to modify the PDF they download, but not modify its watermark. This is probably going to be nigh on impossible if the watermark is embedded in the PDF (afaict) but what if the watermark image is external to the PDF; is it possible to embed a watermark in a PDF that is sourced via HTTP? Then you could embed:

<watermark image="http://sharepoint/site/_vti_bin/docstatus.asmx?id=5">

Of course, I have no idea about PDFs, so this might not be possible but you get the concept.

-Oisin

风筝在阴天搁浅。 2024-09-03 21:16:30

如果您使用第三方工具,则可以这样做。然后,您可以从 SharePoint 元数据、条件、规则等中动态绑定值:http://www.pdfsharepoint.com

It is possible to do so if you use third party tool. Then you can put dynamically binded value from your SharePoint metadata, conditions, rules etc: http://www.pdfsharepoint.com

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文