简体   繁体   English

如何创建动态Infopath表单?

[英]How to create a dynamic Infopath form?

i have a webpart that creates a list dynamically.Now i want to create a infopath form for that list dynamically with the columns of that list only, so that when a user clicks add a document that new infopath should open. 我有一个Webpart可以动态创建列表。现在,我想为该列表动态创建一个信息路径表单,仅包含该列表的列,以便在用户单击时添加一个新的信息路径应打开的文档。

So, in a nutshell, my webpart creates a list with user specified columns and its infopath(which is it's default infopath). 因此,简而言之,我的Webpart会创建一个包含用户指定的列及其信息路径(这是默认信息路径)的列表。

i am using sharepoint 2010,infopath 2010,visul studio 2010. 我正在使用sharepoint 2010,infopath 2010,visul studio 2010。

  1. Deploy your InfoPath form as a site content type. 将InfoPath表单部署为网站内容类型。
  2. Modify the definition of the list created dynamically by your webpart so that the default content type for the list is the one created when you deployed your InfoPath form. 修改由Webpart动态创建的列表的定义,以使列表的默认内容类型是在部署InfoPath表单时创建的列表。

Then, when a user creates an item in the list, the default content type will be used and the InfoPath form will be displayed. 然后,当用户在列表中创建一个项目时,将使用默认的内容类型并显示InfoPath表单。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM