从SP 2013中的Infopath表单中提取附件 [英] Extract attachment from Infopath form in SP 2013

查看:88
本文介绍了从SP 2013中的Infopath表单中提取附件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我需要能够从InfoPath表单中提取附件,我很高兴能够将其转到另一个文档库。我找到了以下文章,但这与2007年有关,我需要它在2013年 -

http://www.bizsupportonline.net/infopath2007/use-workflow-extract-file-attachment-infopath-upload-sharepoint-document-library.htm

I need to be able to extract an attachment from an InfoPath form and I am happy to have it go to another document library. I have found the following article but this relates to 2007 and I need it for 2013 - http://www.bizsupportonline.net/infopath2007/use-workflow-extract-file-attachment-infopath-upload-sharepoint-document-library.htm

这适用于2013年吗? 如果没有,我会对如何做到这一点表示赞赏。 我没有编码经验,但如果有一些明确的指示,我很乐意试一试。

Will this work for 2013?  If not, I'd appreciate some direction on how to do this.  I have no coding experience but I am happy to give it a go if there are some clear instructions.

谢谢!

推荐答案


试试这个 

Try this 


http ://www.infopathdev.com/blogs/ernesto/archive/2012/01/13/extract-attachments-from-your-infopath-forms.aspx

http://www.infopathdev.com/blogs/ernesto/archive/2012/01/13/extract-attachments-from-your-infopath-forms.aspx



据我所知,SharePoint或InfoPath中没有内置任何内容来执行此操作;您必须编写代码。看一下这篇文章  http://support.microsoft.com/kb/892730   for
如何解码附件的base64编码字符串。如果你使用的是VB.NET,您可以查看此InfoPath新闻组主题 http://groups.google.com/group/microsoft.public.infopath/browse_thread/thread/310fca090e9f708f/81376114cd5ee732?hl=en&lnk=gst&q=attachment+disk+infopath#81376114cd5ee732

As far as I know, there isn't anything built into either SharePoint or InfoPath to do this; you would have to write code. Take a look at this article http://support.microsoft.com/kb/892730 for how to decode the base64 encoded string of an attachment. If you're using VB.NET, you can take a look at this InfoPath newsgroup threadhttp://groups.google.com/group/microsoft.public.infopath/browse_thread/thread/310fca090e9f708f/81376114cd5ee732?hl=en&lnk=gst&q=attachment+disk+infopath#81376114cd5ee732


 

 


解码附件后,您可以使用WebClient类(如果从SharePoint外部提取)或SharePoint对象模型的类(如果您是从SharePoint内部的某处提取,以将二进制数据
作为文件上载到SharePoint文档库。

Once you've decoded the attachment, you can use either the WebClient class (if you're extracting from outside of SharePoint) or classes of the SharePoint Object Model (if you're extracting from somewhere inside of SharePoint) to upload the binary data as a file to a SharePoint document library.


 

 


有几种方法可以检索表单并提取附件;这一切都取决于您的要求以及您希望在何时进行提取。您可以使用例如ItemAdded事件表单库中的SharePoint处理程序在表单添加到表单库后立即执行提取
。您也可以通过创建一个可以检索所有表单的实用程序(在SharePoint之外)来提取在表单库中进行提取。

There are several ways to retrieve the form and extract the attachment; it all depends on your requirements and at which moment you want to do the extraction. You could use for example an ItemAdded event handler in SharePoint on the form library to do the extraction as soon as the form has been added to the form library. You could also extract after the fact by creating a utility program (outside of SharePoint) that would retrieve all forms in a form library and do the extraction.


这篇关于从SP 2013中的Infopath表单中提取附件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆