using workflows with InfoPath 2007 forms
Author: mety Labels:: using workflows with InfoPath 2007 formsWhat are workflows?A workflow is sometimes described as a series of tasks that produce an outcome. In the context of Microsoft SharePoint Products and Technologies, a workflow is defined more precisely as the automated movement of documents or items through a specific sequence of actions or tasks that are related to a business process. Workflows can be used to consistently manage common business processes within an organization by allowing organizations to attach business logic to documents or items in a SharePoint list or library. Business logic is basically a set of instructions that specifies and controls the actions that happen to a document or item.Workflows can streamline the cost and time required to coordinate common business processes, such as project approval or document review, by managing and tracking the human tasks involved with these processes. For example, in a Microsoft Office SharePoint Server 2007 site, you can add a workflow to a document library (document library: A folder where a collection of files is shared and the files often use the same template. Each file in a library is associated with user-defined information that is displayed in the content listing for that library.) that routes a document to a group of people for approval. When the document author starts this workflow on a document in that library, the workflow creates document approval tasks, assigns those tasks to the workflow participants, and then sends e-mail message alerts to the participants that include task instructions and a link to the document to be approved. While the workflow is in progress, the workflow owner (in this case, the document author) or the workflow participants can check the Workflow Status page to see which participants have completed their workflow tasks. The Workflow Status page is available by clicking the status of the workflow for a document or item in the document library. When participants complete their workflow tasks, the workflow ends, and the owner is automatically notified that the workflow is complete. The following illustration shows the Approval workflow process. Workflows not only support existing manual work processes but also extend the ways in which people can collaborate and work with documents, lists, and libraries. Site users can start and participate in workflows by using customizable forms that are accessible from the document or item in a SharePoint list or library. These customizable forms are SharePoint pages that help users to review or make changes to the workflow. Additionally, the workflow functionality in Office SharePoint Server 2007 is tightly integrated with the 2007 Microsoft Office system. The following workflow tasks can be performed either in an Office SharePoint Server 2007 site or directly within certain programs that are part of the 2007 Office release:
Ways to use workflows with InfoPath formsYou can create Microsoft Office InfoPath forms that display specific data that corresponds to the current status of a workflow. You do this by designing a form template to use rules (rule: A condition or action, or a set of conditions or actions, that automatically performs tasks based on events and values in the form.) that initiate actions in the form based on the status of the workflow. This can streamline the processes that people use to fill out forms. For example, you can design forms to display a read-only view (view: A form-specific display setting that can be saved with a form template and applied to form data when the form is being filled out. Users can switch between views to choose the amount of data shown in the form.) when the status for a workflow is Complete and, therefore, the data in the form should not be changed.You can also use rules to make forms respond to workflows in other ways. For example, you can use a rule to display a dialog box message that has instructions that are specific to a particular workflow status. Note Dialog boxes will not appear automatically in browser-compatible form templates that users fill out in a Web browser. Workflows must be added to a list, library, or content type to make them available for use in InfoPath forms. The available workflow types for a site vary, depending on the type of site, whether workflows are activated, and whether custom workflows were created by using Microsoft Office SharePoint Designer 2007. Contact your farm administrator to determine which workflows are installed and ready for your site. Each workflow is defined by distinct statuses with descriptive names, such as In Progress. The names for statuses vary according to the type of workflow. For example, an Approval workflow — which is available on servers running Microsoft Office SharePoint Server 2007 — includes a status for In Progress, Canceled, and Completed. The statuses of a Three-state Workflow — which is available in Windows SharePoint Services 3.0 — can be defined by the person who adds the workflow to a library or list, whereas other workflows use standard statuses such as the In Progress status noted previously. Although the descriptive name is visible to the user, workflow statuses are represented programmatically by numeric values. To design a form template to respond to a specific workflow status, you must know the numeric value for the workflow status that you want to use. This is because InfoPath uses the numeric value of the workflow to initiate an action, such as switching views. Workflows that are included in SharePoint sitesThe following workflows address common business scenarios and are included in Windows SharePoint Services 3.0 and Office SharePoint Server 2007. Workflows that are included in Windows SharePoint Services 3.0The Three-state workflow is included in Windows SharePoint Services 3.0 and Office SharePoint Server 2007 sites. The three-state workflow can be used to manage business processes that require organizations to track a high volume of issues or items, such as customer support issues, sales leads, or project tasks. Workflows that are included in Office SharePoint Server 2007An Office SharePoint Server 2007 site also includes the following workflows that address common business scenarios:
Each of the above workflows can be customized for your organization in several ways. For example, when you add a workflow to a list, library, or content type to make it available for use on documents or items, you can customize the tasks lists and history lists, where information about the workflow is stored. When a user starts a workflow on a document or item, depending on the type of workflow, the user may have the option to further customize the workflow by specifying the list of participants, a due date, and task instructions. Support for custom workflows in Windows SharePoint Services 3.0 or Office SharePoint Server 2007Your organization may choose to develop and deploy custom workflows that are unique to the business processes in your organization. Workflows can be as simple or as complex as the business processes in an organization require. Developers can create workflows that are started by site users, or they can create workflows that start automatically based on a specific event, such as when a SharePoint list item or a form in a document library is created or changed. If your organization has developed and deployed custom workflows, these workflows may be available for use on your site. Depending on the people involved in creating the workflow, there are two ways in which custom workflows can be created for Windows SharePoint Services 3.0 or Office SharePoint Server 2007:
If you want to implement a custom workflow, contact your farm administrator for information about available resources in your organization. For more information about developing custom workflows for Windows SharePoint Services 3.0, see the Windows SharePoint Services Developer Center on MSDN. For more information about developing custom workflows for Office SharePoint Server 2007, see the Microsoft Office SharePoint Server 2007 SDK, which is available from the Microsoft Office SharePoint Server 2007 Developer Portal on MSDN. Steps involved in using workflowsThere are several steps involved in using a workflow on a document or item. Each step is designed to be completed by individuals in different roles. For example, a site administrator can add a workflow to a document library, a content creator can start a workflow or modify a workflow in progress, and a document reviewer or an approver can complete the workflow task. The next section explains the following processes associated with using workflows:
Adding a workflow to a list, library, or content typeBefore a workflow can be used, it must be added to a list, library, or content type. You need Manage Lists permissions (permissions: The specific security settings that allow or restrict access to a given item, list, library, or site.) to add a workflow to a list, library, or content type. In most cases, the site administrators or individuals who manage specific lists or libraries perform this task. The availability of a workflow within a site varies, depending on where it is added:
When you add a workflow to a list, library, or content type, you can customize the workflow for its specific location by specifying one of the following options:
Note When you add a workflow to a list, library, or content type, you make it available for documents or items in a specific location. You do not start the actual workflow. Find links to more information about adding workflows to lists, libraries, or content types in the See Also section. Starting a workflow on a document or itemAfter a workflow is added to a list, library, or content type, you can start the workflow on a document or item in that location (if the workflow is configured to allow it to be started manually). To start a workflow, you select the workflow that you want from the list of available workflows for the document or item. If necessary, you may also need to fill out a form with the information that the workflow requires. Depending on how the workflow was designed and configured, when you start the workflow you might have the option to further customize it by specifying such options as participants, due date, and task instructions. Modifying a workflow in progressAfter a workflow has been started, you may need to make changes to it. For example, you might need to add additional participants, or a workflow participant might need to reassign his or her task to another person or request a change to the document or item that is the focus of the workflow. You can modify some of the predefined workflows that are included in Office SharePoint Server 2007 while the workflow is in progress. If your organization has developed and deployed a custom workflow, the ability to change the workflow while it is in progress depends on how it was designed. Completing workflow tasksAny workflow event that requires manual interaction is represented by a workflow task. When a task is assigned to a workflow participant, the task recipient can either complete that task or request changes to the workflow itself by editing the associated workflow task form. In Office SharePoint Server 2007, workflow participants can complete workflow tasks on the SharePoint site or directly within a Microsoft Office 2007 program — such as Microsoft Office InfoPath 2007. When a workflow participant completes a workflow task or requests a change to the workflow, the server is prompted to move the workflow status to the next step in the workflow. Tracking the status of a workflowWorkflow owners and participants can follow the progress of a workflow by checking the status page that is associated with the workflow, in the SharePoint site. The status page includes status information about workflow tasks that are not completed. It also includes history information that is relevant to the workflow. Office SharePoint Server 2007 also includes reporting tools that provide an aggregate analysis of a workflow's history. Organizations can use this analysis to locate areas in processes that need to be improved or to determine whether a group is meeting the performance targets for a given business process. Office SharePoint Server 2007 includes several predefined Microsoft Excel reports that can be used with any workflow. Additionally, workflow history information is available as a SharePoint list data source that can be used and analyzed in other programs, such as Microsoft Office Visio 2007, Microsoft Office Access 2007, Microsoft Office InfoPath 2007, or in a custom business process monitoring solution. |