Take the 2-minute tour ×
SharePoint Stack Exchange is a question and answer site for SharePoint enthusiasts. It's 100% free, no registration required.

I am using sharepoint 2010 and created a visual studio workflow which is creating some tasks and assign it to some user or group. I have deploy for a couple of 3 times new versions to my environment. Before it was always working, but now not anymore. I have try to deploy an old wsp version, but it also not working. How can I debug or find the problem?

The workflow is created at my custom content type. I have a custom list which is using this custom content type. The workflow is triggered when an item is created or updated.

share|improve this question
    
Is the item being created by a system account or a user account? –  lance Mar 7 '13 at 22:36
    
by a user account –  KHA Mar 7 '13 at 22:39
add comment

1 Answer

I would go back in your code in visual studios and either use a try/catch block to find and log the error or you can debug the workflow the following way:

In Visual Studios 2010:

  • Deploy the newest version of the workflow.
  • Go to to Debug -> Attach to Process -> Select w3wp.exe (usually the first one) -> Attach
  • Fire the workflow manually
  • Step through the code to see what causes the error and fix it.
share|improve this answer
    
how can I fire the workflow manually? –  KHA Mar 7 '13 at 22:51
    
Navigate to the item, and use the drop-down menu -> "Workflows" -> then start the workflow from there, or you can select the item and on the top of the ribbon go to the Items/Document tab and click "Workflows" –  Mike Mar 7 '13 at 22:52
    
but the workflow is set to the content type. Are you sure it is possible like you say? I see the workflow button, but I dont see something like start or run. –  KHA Mar 8 '13 at 6:27
    
Make sure you are able to start it manually. Whenever you create a workflow you are given the option to allow the workflow to start manually, automatically from a change, and automatically from a new item. –  Mike Mar 8 '13 at 14:53
    
I did enabled the "manuall start workflow" option, but I cannot again start the workflow manual. Someone told me to restart the sharepoint timer job service. Is this maybe the solution because the workflow timer job is stuck or someting? –  KHA Mar 11 '13 at 9:26
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.