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 new to Sharepoint and using Visual Studio 2008 I have created a workflow that uses custom content type based off workflow task list with additional columns for Approval Status and Approver Notes. Workflow is associated to list A, change or new item in this list creates a task in list B. Can you tell me how, in my workflow, can I get a reference to an item in list A that started the workflow?

share|improve this question
add comment

1 Answer

up vote 1 down vote accepted

There's an attached property SPWorkflowActivationProperties WorkflowProperties. You can get the source item via it's Item property:

SPListItem item = WorkflowProperties.Item;
share|improve this answer
    
just realised this during debugging... many thanks, marking as answered –  Sebastian Jun 18 '12 at 11:59
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.