11 June 2009

Following Robert Shelton's well documented series on creating MOSS 2007 workflows in Visual Studio 2008, I ran across a bit of a snafu. Basically, his recommended dev machine setup stipulates WSS3, VS2008, etc. However the Visual Studio 2008 wizards/templates for Sequential Workflow expect MOSS, not WSS. The workaround should get me positioned to develop, debug, package and deploy workflows in VS2008.

I found the most complete workaround write-up on this issue on the Visual Studio SharePoint Tools Blog by Roger Best. Here is his writeup in full (in case the link stops working one day..)

"Getting Visual Studio 2008 SharePoint 2007 Sequential / State Machine Workflow projects working with Windows SharePoint Services 3.0

Published 19 August 08 02:18 PM

I wanted to create a SharePoint workflow using VS 2008 on WSS 3.0. The documentation is set that only Microsoft Office SharePoint Server 2007 can be used but I figured I would lay out the modifications needed to allow a project to function on WSS 3.0. The four steps are:

1.) Since WSS 3.0 doesn't have a docs site and the wizard is particular about specific "sites" we need to change http://machinename/docs to http://machinename.

If not you will get the message:

"SharePoint site location entered is not valid. The SharePoint site at http:///Docs could not be found. Verify that you have typed the URL correctly. If the URL should be serving existing content, the system administrator may need to add a new request URL mapping to the intended application."

Go ahead and finish wizard with what you need. Once the project has been created

2.) Remove the reference to Microsoft.Office.Workflow.Tasks

Now depending if you are coding in VB or C# you should

3a.) C# open workflow1.cs code editor and remove "using Microsoft.Office.Workflow.Utility;"

or

3b.) VB remove import of Microsoft.Office.Workflow.utility.

4.) Now we have to remove some xml from the feature.xml file specifically

- ReceiverAssembly="Microsoft.Office.Workflow.Feature, Version=12.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c"

- ReceiverClass="Microsoft.Office.Workflow.Feature.WorkflowFeatureReceiver"

Now you should be able to debug the project .

Roger Best"


refs:


another day, another lesson.

No comments:

Post a Comment

firstly, thanks in advance for your comment - I don't get very many, so I'm sure to follow up if you leave me a way - secondly, come again.