Supporting Form Libraries in Meeting Workspace Sites

By default, you cannot add form libraries to Meeting Workspace sites. However, you can configure Meeting Workspace sites to support form libraries by performing the following steps.

Configure Meeting Workspace sites to support form libraries

  • Add the following line from \Program Files\Common Files\Microsoft Shared\Web Server Extensions\60\Template\1033\STS\XML\ONET.XML to \Program Files\Common Files\Microsoft Shared\Web Server Extensions\60\Template\1033\MPS\XML\ONET.XML in the <ListTemplate> tag:

    <ListTemplate Name="xmlform" DisplayName="Form Library" Type="115" BaseType="1" OnQuickLaunch="FALSE" SecurityBits="11" Description="Create a form library when you have XML-based business forms, such as status reports or purchase orders, that you want to manage. These libraries require a Microsoft Windows SharePoint Services-compatible XML editor, such as Microsoft Office InfoPath 2003." Image="/_layouts/images/itdl.gif" DocumentTemplate="1000"></ListTemplate>
    

    This registers the list template for use with Meeting Workspace sites.

    Warning  It is recommended that you create a custom site definition by copying an existing site definition, rather than modifying the original ONET.XML file installed with Windows SharePoint Services. Changes that you make to the originally installed file may be lost when you update Windows SharePoint Services such as through service packs or patches. For information on creating a custom site definition, see Creating a Site Definition from an Existing Definition.

  • Copy \Program Files\Common Files\Microsoft Shared\Web Server Extensions\60\Template\1033\STS\DOCTEMP\XMLFORM to \Program Files\Common Files\Microsoft Shared\Web Server Extensions\60\Template\1033\MPS\DOCTEMP\.

  • Copy \Program Files\Common Files\Microsoft Shared\Web Server Extensions\60\Template\1033\STS\LISTS\XMLFORM to \Program Files\Common Files\Microsoft Shared\Web Server Extensions\60\Template\1033\MPS\LISTS\.

  • Run the IISReset command.

New Meeting Workspace sites will now support form libraries.

Add a form library to a Meeting Workspace site

The following code example adds a form library to your Meeting Workspace site.

[C#]

SPVirtualServer TargetServer = new SPVirtualServer(new Uri("http://server_name"));
SPSite TargetSite = TargetServer.Sites["http://server_name"];
SPWeb RootWeb = TargetSite.OpenWeb("/");
SPWeb MWSWeb =    RootWeb.Webs.Add("mwsformtest", " mwsformtest ", "Form Library MWS Test", 1033, "MPS", false, false);
MWSWeb.Lists.Add("FormLib", "FormLib", SPListTemplateType.XMLForm);