SharePoint Guidance: First Release


The first release of SharePoint Guidance from the Microsoft Patterns & Practices SharePoint Guidance team is now published on Codeplex at

Disclaimer: This will evolve (and change) significantly. At this stage the RI provides a basic set of WSS features with accompanying guidance. This is not a CTP or a BETA.

Stay tuned for new releases about every two weeks or so.

Deployment issues using Visual Studio 2008 SharePoint Workflow project templates (Access is denied.)

The addition of SharePoint sequential and state machine workflow project templates to Visual Studio 2008 did wonders for SharePoint workflow developers. Specifying SharePoint Debug Settings that allow you to do a “right-click Deploy” that GACs the DLL, installs and activates a workflow on a SharePoint instance, and associates it with a SharePoint list on that instance eliminates a lot of manual steps.
There is one issue, however, that arises when the workflow project is under source control. This issue yields the following errors in Visual Studio:
“Access is denied.”
“Cannot copy workflow.xml to C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\12\TEMPLATE\FEATURES\[Project Name]\workflow.xml.”

“Cannot copy feature.xml to C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\12\TEMPLATE\FEATURES\[Project Name]\feature.xml.”

Unfortunately for the first few months I just dealt with this issue using this workaround:
1. Open the path to the workflow feature folder.
2. Delete feature.xml and workflow.xml.
3. Go back to Visual Studio and click Deploy.
I finally realized that when the Deploy command in Visual Studio for the workflow projects does a copy of the feature files to the 12 hive, it copies the read-only attribute as well if you do not have those files checked out in source control.
If you are having this issue, simply check out feature.xml and workflow.xml from source control and your deployments with SharePoint workflow project templates should no longer have this error.