开发者

Sharepoint 2010 workflow with custom infopath form

I am trying to figure out how to use a custom Infopath form with a Sharepoint 2010 workflow. I have read about a million tutorials on how to do this, but I always end up receiving a "The workflow templa开发者_如何学运维te has specified no FormURN for this page." error.

I use a Visual Studio project to deploy the solution. I have a Module containing the .XSN form in a "Forms" folder and of course the Workflow itself.

After tons of googling I think these settings should be correct:

My Form Module def:

<?xml version="1.0" encoding="utf-8"?>
<Elements xmlns="http://schemas.microsoft.com/sharepoint/">
  <Module Name="OPF" Url="FormServerTemplates" RootWebOnly="TRUE" xmlns="http://schemas.microsoft.com/sharepoint/">
    <File Path="Travel.xsn" Url="Travel.xsn" Type="GhostableInLibrary" />
  </Module>
</Elements>

My Workflow def:

<?xml version="1.0" encoding="utf-8" ?>
<Elements xmlns="http://schemas.microsoft.com/sharepoint/">
  <Workflow
     Name="Godkjenning av timelister"
     Description="My SharePoint Workflow"
     Id="d92ce465-4fbd-46ee-9e44-ff0320d2bb75"
     TaskListContentTypeId="0x01080100C9C9515DE4E24001905074F980F93160"
     CodeBesideClass="OPFWorkflowTest2.Godkjenning_av_timelister.Godkjenning_av_timelister"
     InstantiationUrl="_layouts/IniWrkflIP.aspx"
     CodeBesideAssembly="$assemblyname$">
    <Categories/>
    <MetaData>
      <AssociationCategories>List</AssociationCategories>
      <MetaData>
        <Instantiation_FormURN>urn:schemas-microsoft-com:office:infopath:Travel:-myXSD-2005-10-21T21-12-27</Instantiation_FormURN>
      </MetaData>
      <StatusPageUrl>_layouts/WrkStat.aspx</StatusPageUrl>
    </MetaData>
  </Workflow>
</Elements>

My Feature def:

<?xml version="1.0" encoding="utf-8" ?>
<Feature xmlns="http://schemas.microsoft.com/sharepoint/"
ReceiverAssembly="Microsoft.Office.Workflow.Feature, Version=14.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c"
   ReceiverClass="Microsoft.Office.Workflow.Feature.WorkflowFeatureReceiver">
  <Properties>
    <Property Key="GloballyAvailable" Value="true" />
    <Property Key="RegisterForms" Value="Forms\*.xsn" />
  </Properties>
</Feature>

I have published the form from Infopath as an "Administrator approved form template". After I deploy the Visual Studio Solution the form is displayed in the "Central Administration -> Manage Form Templates" list and is marked as "Workflow Enabled=Yes". I get the No FormURN error no matter how I use the form in the workflow. For instance if I try to use it with a task.

Additional things I have tried:

- Used both Infopath 2007 and 2010

- Security on Infopath form is "Domain"

- The alternate access path is left empty when publishing the form

- Used two completely separate environments

- Endless combinations of different settings in the XML files

It seems like some people have managed to get this to work, but no matter what I do it doesn't work for me.

Here is a link that discuss this problem with various solutions (that doesnt work for me):

http://social.msdn.microsoft.com/Forums/en-US/sharepoint2010programming/thread/fac26787-1729-46c8-9021-80652b3734c8

Can only list 1 link on Stack Overflow... first post. Typical...

So if there is any Sharepoint experts out there, please help me resolve this problem! This is the kind of thing that makes me question the whole product!


I'm able to see the InfoPath form after associating with VS 2010 workflow, please find below article on my blog to verify publishing InfoPath form and let me know if you need any help to resolve above issue.

http://sumansharepoint.blogspot.com/2008/05/points-to-remenber-when-designing.html these steps are same for both InfoPath 2007 and 2010 forms.

Please find below my feature.xml and elements.xml files

Workflow.xml

Name="MyWorkflow" -->

List

  <Task0_FormURN>urn:schemas-microsoft-com:office:infopath:ApprovalForm:-myXSD-2011-01-13T09-41-32</Task0_FormURN>
  <StatusPageUrl>_layouts/WrkStat.aspx</StatusPageUrl>
</MetaData>

Feature.xml

I did not see element manifest entry on your feature.xml code, please verify that.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜