Sitecore 5.0 API

ItemIDs.WorkflowRoot Field

The ID of the root item of the system/workflows section

[Visual Basic]
Public Shared WorkflowRoot As ID
[C#]
public static ID WorkflowRoot;

Example

The following example retrieves the workflow root item, under which workflows are defined.

{{{
public Item GetWorkflowByName(string name) {
  Item root = Sitecore.Context.ContentDatabase.Items[ItemIDs.WorkflowRoot];
  if (root != null)  {
    return root.Children[name];
  }
  return null;
}
}}}

See Also

ItemIDs Class | Sitecore Namespace