How to debug Sequential workflow and state machine workflow?

Hi All,
How to debug Sequential workflow and state machine workflow?
Thanks in Advance!

check this
http://msdn.microsoft.com/en-IN/library/bb386166(v=vs.90).aspx
http://msdn.microsoft.com/en-us/library/vstudio/ee231573(v=vs.100).aspx

Similar Messages

  • How to Create Step By Step Sequential And State Machine Workflows?

    Hi All,
    I am very new to workflows, can any one help me to how to create workflows step by step using visual studio.
    Can any one explain with example.

    Hello,
    Here is the MSDN article for your ref:
    Sequential WF:
    http://msdn.microsoft.com/en-us/library/office/gg265727%28v=office.14%29.aspx
    State Machine WF:
    http://msdn.microsoft.com/en-us/library/office/gg508985%28v=office.14%29.aspx
    Hope it could help
    Hemendra:Yesterday is just a memory,Tomorrow we may never see
    Please remember to mark the replies as answers if they help and unmark them if they provide no help

  • How to REpublish Custom Task Forms (InfoPath) to SharePoint 2010 State Machine Workflows

    I am new to SharePoint. Sorry if answer to my question is obvious.
    I've create Custom Task Form in InfoPath and publish it (File/Publish/Network Location [Form Template Path and filename='MYPROJECT/Forms/ApprovalForm.xsn'; Form template name='ApprovalForm'], in the next window I've cleared Public URL according to the articlehttp://www.codeproject.com/Articles/195348/SharePoint-2010-State-Machine-Workflows-with-Custo).
    After it I've added module Forms, and added ApprovalForm.xsn from the existing items.
    My xml files: Elements.xml
    <Elements xmlns="http://schemas.microsoft.com/sharepoint/">
    <Workflow
    Name="Order New Server"
    Description="My SharePoint Workflow"
    Id="482cbc86-b717-4981-a49a-3cf4c89e9399"
    CodeBesideClass="Myproj.OrderNewServer.OrderNewServer"
    CodeBesideAssembly="$assemblyname$"
    TaskListContentTypeId="0x01080100C9C9515DE4E24001905074F980F93160">
    <Categories/>
    <AssociationData><Data></Data></AssociationData>
    <MetaData>
    <AssociationCategories>List</AssociationCategories>
    <Task2_FormURN>urn:schemas-microsoft-com:office:infopath:ApprovalForm:-myXSD-2012-03-09T14-11-55</Task2_FormURN>
    <StatusPageUrl>_layouts/WrkStat.aspx</StatusPageUrl>
    </MetaData>
    </Workflow>
    </Elements>
    Feature.Template.xml:
    <?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" Receiverlass="Microsoft.Office.Workflow.Feature.WorkflowFeatureReceiver">
    <Properties>
    <Property Key="GloballyAvailable" Value="true" />
    <Property Key="RegisterForms" Value="Forms\*.xsn"/>
    </Properties>
    </Feature>
    My form work fine, but when I make changes and republish it, it doesn't update (I see old form). What I tryed:
    IISReset
    Clear all cookies and cache in IE
    Retract solution, restart VS2010, reboot computer.
    Change assembly number, guid.
    I have no ideas, what can I try for republish my form with changes.
    Thank you in advance for any suggestions.
    PS: sorry for my writing. English is not my native language.
    PPS: when I save new Form to new location and add it to the project, it works.

    I've found how can I republish changes. But it seems more like crutch than solution, but it works:
    After republishing InfoPath form, I delete file from project (DEL on ApprovalForm.xsn in Solution explorer) and after it add it again. (Add/Existing Item). And then redeploy! Hurray!
    Is there any way to redeploy a Task Form directly on the server without importing it in Visual Studio again? I am using some data connections in my task form which are different for different environments (staging, dev. etc.). Seems like I've to create a separate
    Workflow WSP file for each envrionment. Any comments?

  • How to update task status from custom task in state machine workflow

    i m using custom task for state machine workflow
    i am using
    if(this.onTaskChangedSupervisorAction_AfterProperties.ExtendedProperties["Workflowstatus"].ToString().Contains("Approved"))
    if above is true moving forward its working fine but i want to update the status field of task as i can update the title and due date for the task but how can i change the status once approved it
    should show the status as approved it's only showing in progress
    this.CreateTaskSupervisorAction_TaskProperties.Title="supervisor task"
    MCTS,ITIL

    If your task shows In Progress state then I think you need to look at your workflow and make sure you are using Complete Task activity and if you are already using Complete Task Activity then verify the Correlation ID. Ideally you are not required to set
    this value in workflow. You simply use the Complete Task Activity.
    If you are running into issue where your workflow is staying in In Progress state even after the task is complete then you can look at the following blog post.
    How to programmatically complete Approval workflow task
    Amit

  • State Machine workflow if else branch

    I have a scenario that have 4 level of approvals on every approval if it is accepted it is coming to the requestor who submitted it i need to make a condition that
    Approval level1=Supervisor
    Approval level2=Dept Manager
    Approval level3=VP
    Approval Level4=HR committee
    request is submitted by reguester a user
    if requester reject the approval level 1 it should move to the target state 2 (Approval level2)
    if requester reject the approval level 2 it should move to the target state 3(Approval level3)
    if requester reject the approval level 3 it should move to the target state 4(Approval Level4)
    i have a state for requestor where once the requester reject i have to move it to one target state
    how can i acheeive above bold requirements?
    MCTS,ITIL

    This is easy to do if you are using Visual Studio to create your workflow.  Simply define each Approval level as a different state and evaluate what the target state should be at the end of each state.
    But if you want to do this using SharePoint Designer then you should know that SPD only does sequential workflows, not state machine.  To do this kind of workflow in SPD most people break it into 5 workflows.  One main workflow and 4 separate workflows
    for each stage.  Then at the end of each workflow decide which other workflow to start. 
    Paul Stork SharePoint Server MVP
    Principal Architect: Blue Chip Consulting Group
    Blog: http://dontpapanic.com/blog
    Twitter: Follow @pstork
    Please remember to mark your question as "answered" if this solves your problem.

  • Stat machine workflow task workflow status different values on different state activity(Approval level)

    i have developed the State machine workflow in which i am using default workflow task
    i have added one status dropdown and that is having approve or reject that i set using workflow task drop down values
    now my requirement is that when my workflow goes to different approval i need to have different status values in dropdown
    for example
    on manager approval state activity i need to add additional status value forward to legal
    but when it moved to next activity this task status field should show only approve and reject
    in summary i need to have different status values for workflow task when it moved to different state activity(approval levels)
    can we set these status field of task for state machine workflow programtically as well like for different approval level of task i need different status to be set for the dropdown of task status field
    MCTS,ITIL

    Hi Shahid Siddique,
    I have seen a similar thread from you about this issue, create custom form for the seperate form is a considerable workaround, you can have a check whether it works.
    http://social.technet.microsoft.com/Forums/en-US/9baa0c32-1cde-4c58-aa7c-3568ccf0cdc9/different-approval-level-of-task-i-need-different-status-to-be-set-for-the-dropdown-of-task-status?forum=sharepointdevelopmentprevious
    Thanks,
    Qiao Wei
    TechNet Community Support

  • How to debug a program exit in a Workflow ?

    Hi experts,
                      How to debug a program exit in a workflow when the workflow is triggered ?
    thanks in advance
    regards
    Ashwin

    In 4.6c I did this by creating a function module and a table (zsm50_debug). In the table are just two fields: User name (key), and a flag (yes/no).
    The function module:
    FUNCTION zsm50_debug.
    *"*"Local interface:
    *"  IMPORTING
    *"     REFERENCE(Z_DEBUG_USER) LIKE  SY-UNAME
      DATA: z_exit,
            z_debug.
      CLEAR: z_debug.
      DATA: starttime   TYPE t,
            currenttime TYPE t,
            time_passed TYPE i.
      starttime = sy-uzeit.
    * Check if debugging is switched on
      SELECT SINGLE debug FROM  zsm50_debug
                          INTO  z_debug
                          WHERE uname = z_debug_user.
    * Debugging is switched on:
      IF z_debug = 'X'.
    *   Not an endless loop, but it will continue after approx. 1 minute...
    *   Plenty of time to go to SM50 to debug the program and continue!
        DO.
    *     Change the value of z_exit to 'X' to exit the loop an stay in
    *     debug mode.
          IF z_exit = 'X'.
            EXIT.
          ENDIF.
    *     To prevent an endless loop (if the user forgot that debugging was
    *     switched on in ZSM50_DEBUG, time is measured to allow the program
    *     to continue after 2 minutes
          GET TIME FIELD currenttime.
          time_passed = currenttime - starttime.
          IF time_passed > 120.
            WRITE: / '!!!==========================================!!!'.
            WRITE: / '!!!DEBUGGING STILL SWITCHED ON IN ZSM50_DEBUG!!!'.
            WRITE: / '!!!    Program was delayed by two minutes    !!!'.
            WRITE: / '!!!==========================================!!!'.
            EXIT.
          ENDIF.
        ENDDO.
      ENDIF.
    ENDFUNCTION.
    This FM reads the table and checks if the flag is switched on. If so, it loops for two minutes. After that, it continues regardless. If not flagged, it continues immediately.
    This way, you can debug any program that is running in the background.
    In every method I program I add this FM right in the beginning. With authorization for SM50, I can then debug the program (in production it may be difficult to get the correct server, if there are more).

  • Using SPUtility.SendEmail inside a state machine workflow not working

    I have a State Machine Workflow. I have developed in visual studio 2010 for a SharePoint 2010 site. I want to send emails to couple of people inside an activity and my code will decide the email receiver. When I assign the task from my code to some one the
    State Machine workflow is sending mail to the task assignee and assigning the task to that person. But if I want to send mail to some additional person from the workflow, it is not allowing me to send that. The code I am using for the same is, SPUtility.SendEmail(SPContext.Current.Web,
    headers, mailBody);
    Can any one please let me know, why it is not sending mail with this code, or what can be the solution for the same.
    Thanks

    Hi Monali,
    Thanks for your sharing.
    Best regards,
    Patrick
    Patrick Liang
    TechNet Community Support

  • SharePoint 2013 State Machine Workflow Developped using Visual Studio 2013 Terminated

    Hi all,
    I developped a state machine workflow using Visual Studio 2013, and deplyed to SharePoint 2013, the workflow work fine for first task, and some times for second task.
    after that the workflow become terminated with below error:
    - System.Activities.Statements.WorkflowTerminatedException: The workflow instance exceeded the throttle of 10000 activities executed in a row and could not be unloaded because it was not persistable.
    I spent many days to solve this issue but witout any result...
    Please advice...

    Hi,
    According to your description, there seems an endless loop in your workflow which makes the workflow exceed the throttle.
    A suggestion is that you can create a new clean sample state machine workflow firstly, when it works without error, then adding other activities with custom logic
    gradually.
    By doing this, it would be easier to find out what might cause the error in this workflow.
    A demo about Create State machine Workflow In SharePoint 2013 for your reference:
    http://www.splessons.com/2013/12/create-state-machine-workflow-in-sharepoint-2013-using-visual-studio-2012/
    Best regards,
    Patrick
    Patrick Liang
    TechNet Community Support

  • Create Multiple tasks for Single Item in List using state machine workflow in sharepoint

    Hi,
    I want to create multiple create tasks for Single Item in List based on Assigned to column using state machine Workflow through visual studio
    Here Assigned to column allows multiple users. so i have to create task for every user based on column .
    I'm trying for this but i didn't got any solution
    Please provide solution for this.

    Hi,
    According to your post, my understanding is that you wanted to allow multiple users to approve.
    There are some articles about creating parallel tasks in state machine workflow, you can have a look at them.
    http://www.codeproject.com/Articles/477849/Create-Parallel-Task-in-State-Machine-Workflow-in
    http://msdn.microsoft.com/en-us/library/office/hh128697(v=office.14).aspx
    http://social.technet.microsoft.com/Forums/office/en-US/b16ee858-4360-479a-a686-4ee35b7be9db/sharepoint-2010-workflow-creating-multiple-tasks?forum=sharepointdevelopmentprevious
    Thanks & Regards,
    Jason
    Jason Guo
    TechNet Community Support

  • Diffrences Between SAP HR workflow and SAP Logistics workflow

    Hello All,
                     Do we need to do any specific configuration settings to be done in the system to work on SAP HR workflow in ECC 6.0?
    I am using SWU3 for automatic workflow customizing?  But I am getting error indicator for u201CCheck Entries from HR Control Tablesu201D in the Maintain Definition Environment Node. 
    Are there any major differences between SAP HR workflow and SAP Logistics Workflow?
    Regards
    Venkat

    Hi Mike,
          what can be the impact if Check Entries from HR Control Tables setting are not maintain in the System. caz my workflow is going in waiting status and when i have chacked the container for that element then there in _Workitem.ExecuteByUser-ID is coming as <NOT SET>.
    So can you please put some light on this.. that what can be the resion behind this ...?
    Is this a Check Entries from HR Control Tables Problem or any other reason..
    Thanks & regards
    Dev

  • How to create State machine workflow?:

    How to create State machine workflow

    Hi,
    According to your post, my understanding is that you want to send email to Assigned to person when item is created in Task List.
    You can set E-Mail Notification to Yes under your Workflow Tasks list > Settings > Advanced Settings. By doing so user specified in AssignedTo will receive e-mail notification when task is created.
    Here is a similar thread for your reference:
    https://social.technet.microsoft.com/Forums/office/en-US/44f63c3c-8dfc-4f02-b627-a92249404ae3/task-list-advance-settings-email-notification-send-email-when-ownership-is-assigned-or?forum=sharepointgeneral
    Best Regards,
    Linda Li
    Linda Li
    TechNet Community Support

  • Guide or Information to Create State Machine workflow on SharePoint Designer 2013

    Hi All,
    I am currently working on a workflow that requires 5 approvers who can approve, reject or review and submit again.
    In a situation where an approval is given, the flow goes to the next approver.
    Where it is Review and Submit Again, the control is transferred to the originator who started the the workflow and the entire process restarts
    When it is a reject, the workflow stops.
    Kindly advice on how to get this working.
    Best Regards,
    Ifeatu
    Ifeatu Osegbo

    Hi
    Ifeatu ,
    For achieving your demand, you can take steps as below:
    Add a “Start a task process” action in your workflow.
    Click “these users” and Start a Task Process edit page will pop up.
    In the Participants field, input your 5 approvers based on the order of approval.
    In the right of Participants field, select “Serial (one at a time)”.
    In the Task Options section, select “Wait for specific response” for Completion Criteria.
    For Required Outcome, select “Rejected”.
    Go to workflow setting page, select “Start workflow automatically when an item is created” and “Start workflow automatically when an item is changed” for the Start Options
    setting.
    Best Regards,
    Eric
    Eric Tao
    TechNet Community Support

  • Link State machine Workflow to Content Type

    State machine Workflow

    Hi ,
    What purpose do you use the drop down column for?
    Assuming the values of the drop down are No/Yes, you can create the reusable workflow like the screenshot:
    Note: as you only want to have this workflow for a particular content type, you need to use SharePoint 2010 workflow platform.
    Best Regards,
    Wendy
    Wendy Li
    TechNet Community Support

  • Change or Restart Workflow and Skip to Workflow

    You have the option in server settings to "Restart current workflow for the selected projects", with the choices of skipping to current workflow stage or to a particular workflow stage. Using a new 2013 project server workflow neither of these
    choices work. The project in each case is returned to the very first workflow stage.
    Is this a bug or badly designed workflow?
    Is this also the case with legacy 2010 workflows?
    rgds
    Mike
    Mike Mahoney

    Mike,
    Thanks to John on the Product Team, I think I can explain what is going on.
    I am going to assume you have a workflow similar to the one below? Some simple logic, a wait event and a transition or some type.
    As the workflow progresses in the above case, it will log a message out, then wait for the submit button to be pressed before transitioning.  If you try to use the Change / Restart workflow function and choose Restart  > Skip to Stage 3, what
    you will see is the workflow restart, log Stage 1 to the history list, and then wait for input. There is no skipping through as the workflow is waiting for the event.
    The new workflows, whilst allowing looping etc, are essentially still sequential in nature, so to skip though the various stages, they need to start at the beginning and then progress through the stages depending on the logic in the stage transitions.
    Just like in 2010, to get something to progress, you need to introduce some special 'Skip to Stage' logic (for want of a better phrase), with this logic, you can tell the workflow 'If the workflow is being run normally, or restarts the workflow and includes
    this stage' execute the actions within. This is achieved by using the 'Include Stage' condition I mentioned in a post above.  In the example below, I have wrapped the logging and the Wait for submitted event in an 'Include Stage' action (and added
    some extra logging)
    Now when this workflow runs normally, it will go through and execute everything, including the bits inside the 'Include Stage' action because the workflow was started normally (as in the name). 
    However, if I choose to restart > Skip to Stage 3 for instance, the workflow will realise it is in 'Skip to Stage' mode and not execute anything in the 'Include Stage' action as the workflow is not being run normally, nor is that stage included (we
    are skipping to Stage 3). As the Wait for Submit is not executed, the workflow will not wait for the submit button to be pressed and progress without issue to the desired stage. From a logging perspective, you should see something like 'Stage 1 > Leaving
    Stage 1 > Stage 2 > Leaving Stage 2 > Stage 3 > Included Stage 3.
    It took some time, but I hope that explains what your seeing. If it doesn't, well it does give a good overview of how to use Skip to Stage logic in 2013 workflows.
    Alex Burton
    www.epmsource.com |
    Twitter
    Project Server TechCenter |
    Project Developer Center |
    Project Server Help | Project Product Page

Maybe you are looking for

  • PROBLEM WITH MY CLA- DEPRECATED CODE

    Hi all, I really need some help to sort out my small class which generates a random string. Here is the code: package project_gui; import java.util.Random; //Random string generator class         public class randomString {                 private st

  • HT5312 How can I get an activation locked phone to its original owner?

    I recently purchased an iPhone 5 on eBay that was locked with the apple logo on it (As told by the seller who said he purchased it from someone else.  So I had expectations of a possible Activation lock on the phone).  When I reset the phone, I found

  • WWSAPI - Cannot connect to web service via SSL and HTTP proxy authentication with NTLM, errorCode 0x803d0016, HTTP status 407

    Hi, I built a web service client using WWSAPI. The connection works via SSL (without HTTP proxy) and it works with SSL and proxy with basic authentication as well. When I try to connect using a proxy with NTLM authentication, then I get the errorCode

  • CIF Queues lie with ready or sunning status.

    Hi Experts, We are experiencing that CIF queus are lieing in ready or running status for some of the order types - not all. We use inbound setting. Inbound to SCM sales orders and deliveries lieing like this. And inbound to ECC production orders are

  • New revision for a metadata only content

    Hi all, I'm using Webcenter Content (UCM) 11.1.1.6 and client is using a kind of documents without file associated. It's working fine with the AllowPrimaryMetaFile=true and createPrimaryMetaFile=1 variables, but client needs to have revisions of this