The example which follows is an illustration of how to set up a
basic workflow process for a workflow triggered by an e-mail
listener. Use these instructions as a guide when creating your
first workflow, substituting the applicable data and settings for
the context of your environment, and for the type of event listener
you will be using.
Note: This exercise assumes that Process
Manager has been installed, the workflow database created, the
necessary e-mail server and user/group connections set up, and that
the Process Manager services have been started on the server.
Successful completion of this sample workflow depends on a
properly-configured e-mail listener. You will also need to provide
the attributes and settings for your environment, including:
The login information to access the e-mail account
that the listener will be monitoring (server name/type, mailbox
name, User ID and password for this account).
A simple text file which defines the content and
format the employee will be required to use when sending the
request to the Help Desk. This is the specific e-mail content that
the e-mail listener will be “listening” for, and will serve as the
trigger to activate the workflow.
The user IDs of the workflow participants (employee,
manager, and Help Desk).
Any field mappings that may be needed to pass any
required data (requester's name, description of hardware needed,
etc.) to the workflow.
Creating a workflow
Creating and deploying a workflow generally involves completing
the following procedures:
Create the workflow layout.
Create an event listener.
Create e-mail templates.
Finalize the workflow and assign the attributes.
Start the event listener.
In this scenario, an event listener has been programmed to
monitor the organization's Help Desk e-mail account. When a
qualifying e-mail arrives, the listener kicks off the workflow.
When the workflow starts, it sends an e-mail to a designated
manager for approval of a new hardware request. If the manager
approves the request, the workflow e-mails the employee and sends
an assignment to the Help Desk to install the new hardware. If the
request is not approved, the workflow sends an e-mail to notify the
employee the request was denied. All activity and responses are
automatically recorded in the workflow log file.
Step 1: Create the workflow layout
To begin, we will create the basic workflow layout, add the
necessary actions, and define the sequence in which the actions
should take place.
Click Start | All Programs | LANDesk
Process Manager | Process Designer.
Choose the Process Manager server and click
In the workflow explorer, right-click Workflows |
New | Folder, then enter Sample workflows for the folder
Right-click Sample workflows, click New |
Workflow, then enter Hardware request for the workflow
Double-click Hardware request to open the new
workflow on the design canvas.
In the Actions toolbox on the right side of the
screen, find the Get approval action in the System group,
and drag and release its icon underneath Hardware request on
the canvas. This adds the Get approval action to the
workflow, along with its required outcome options, Approved
and Denied. (Whenever you drag an action to the canvas, any
required outcomes are automatically inserted in their relative
position on the canvas.)
Drag the right scroll bar on the Canvas pane downward
to move the window to display enough empty space to add several
more actions below the existing icons.
In the System group in the Actions toolbox, drag and
drop the Send email action underneath the Approved
icon on the canvas. Then drag another Send e-mail action and
drop it underneath the Denied icon on the canvas.
Find the Assign manual task icon in the System
group in the Actions toolbox and drag it to the left of the
Approved icon on the canvas.
Click the Hardware request icon at the top of
the layout, hold down the left mouse button, and drag in a downward
direction, releasing the button on the Get approval action.
This draws an arrow from the Primary action (Hardware
request) to the Get approval action, and establishes the
sequence in which those actions are to take place.
Use the technique described above to draw arrows
from the Approved outcome to its Send e-mail action,
and from the Denied outcome to its Send e-mail
action. Then draw an arrow from Approved to Assign manual
Click the Layout diagram button on the
toolbar to refresh the display and have Process Designer align
and space the actions on the canvas.
Click Validate (green checkmark icon) in the
Validation panel at left side of the screen, and note the
comments listed. These indicate the attributes that need to be
defined for each of the actions, before the workflow can be
deployed. We will define these attributes and set their properties
in Step 4: Finalize the workflow and assign the attributes
For now, click the Save button on the toolbar
to save the workflow layout.
Step 2: Create an event listener
The next step is to create the event listener. If the triggering
event was a database entry, you would create a database listener;
if you wanted it to be triggered by a web service, you would create
a web service listener. In this case, we need to monitor the Help
Desk e-mail Inbox, so we will create an e-mail listener. Once it
has been started, it will "listen" to the designated e-mail
account, and when the trigger e-mail arrives, the listener will
start the workflow.
To complete this section, in step 14 you will need an e-mail
content definition file. This is a simple text file that specifies
the content the listener needs to listen for. For this example, a
sample definition file, EmailListenerSample.txt is included
in the Program Files\ LANDesk\Process Manager\WorkflowManager
On the toolbar, click Configure | Event
Click Add to create a new event listener.
On the Type tab, select E-mail.
Click the Details tab.
In the Name text box, type Hardware request
In the Workflow to start box, click the
[...] (ellipsis) button, click the plus sign next to
Sample workflows, select Hardware request, and click
Click the Settings tab.
In the Mail server
type dropdown list, select IMAP or POP3.
In the Mail server text box, type the name of
the mail server where the e-mail account resides.
(If you selected IMAP in Step 8) In the Mailbox
name text box, type the name of the mailbox or folder to be
(If you selected POP3 in Step 8) Since with POP3 you cannot specify
a mailbox name, it is recommended that you use a dedicated email
In the User Id text box, type the user ID for
the account the listener will be monitoring.
In the User password text box, type the
password to access the user account.
Click Test to test the connection to the
e-mail account using the login and authentication information you
provided. If the listener was able to contact the specified e-mail
account, a message will appear, indicating a successful connection.
If not, you may need to re-type the information, user ID, or
password. When the connection is successful, click
Click Open, navigate to and select the e-mail
content definition text file, and click OK. This inserts the
content the listener needs to listen for in the Sample e-mail
content text box.
When you are satisfied with the e-mail content,
click the Mappings tab.
Click Autogenerate external unique system
In the Requester dropdown list, select
Click Autogenerate field mappings, then click
Yes to save the event listener.
Click OK, then click Close.
Step 3: Create e-mail templates
Creating e-mail templates enables you to set up the messaging
that will be used to assign tasks, request approvals, notify
participants of workflow actions, etc. For this example, we will
create a template to send an e-mail to a manager to request
approval for purchase of new computer hardware.
On the toolbar, click Configure | Templates |
Click Add to create a new e-mail
In the Name text
box, type Approval request.
In the Action drop-down list, select Get
approvals. This adds the template you are creating to the
dropdown list you will use later on to specify which e-mail
template you want to use.
In the Sender text box, type the name or
e-mail address you want to appear in the From field of the
e-mail message. For this example, type Help Desk.
In the Subject text box, type the subject of
the e-mail. For this example, type Your approval is
In the Message body text box,type the
One of your employees has requested a new monitor. Please
use the buttons below to approve or deny this request. Thank you.
Click OK to save the e-mail template.
Refer to the above instructions to create three more
e-mail templates: a) to notify the employee if the request is
approved, b) to notify the employee if the request is denied, and
c) to assign a task to the Help Desk or IT staff to install the new
When you are finished, click OK to close the
E-mail Template Manager dialog box.
Step 4: Finalize the workflow and assign the attributes
Sometimes, after creating the basic workflow design, preparing
e-mail templates, and setting up the event listener, other needs or
tasks become apparent. If so, you can add them before finalizing
Once you are satisfied with the workflow, you need to make sure
all required attributes are configured. The Validation panel
to the left of the canvas is where Process Designer reports any
missing attributes. We'll use the Validation panel to
resolve any missing attributes.
To assign the required attributes
Click Validate (green checkmark icon) in the
Validation panel to refresh the screen and make sure all
actions have been verified and issues reported.
Double-click the first validation message, Missing
Below the empty list of approvers, click
In the Contact type dropdown list, select
In the Contact location dropdown list, select
the location where the approver's network account resides (local
machine, domain, etc.)
In the Search filter text box, type an
asterisk (*), or type the first few characters of the approver's
name, followed by an asterisk, and click Search.
Select the approver from the Available
contacts list, and click OK.
At the bottom of the Attributes panel, click
In the list of e-mail templates Select Approval
request and click OK.
Click Validate and note that the Missing
approval recipient message is removed from the list.
Double-click the next validation message, Missing
Using steps 1-10 above as a guide, assign the
attributes for e-mail templates and notification recipients for the
Approved and Denied outcomes.
Click the validation message for Missing
assignment recipient and specify the assignment recipient and
the e-mail template to assign the hardware installation to the Help
Click the Validate button and make sure no
more comments remain in the Validation panel.
Save the workflow.
Step 5: Start the event listener
With the workflow design, e-mail templates, and event listener
configured, you are ready to automate the process by starting the
Click Configure | Event listeners .
Select Hardware request e-mail listener from
Click the Details tab.
Click Start listener.
Click OK to close the Event listener dialog
The e-mail listener will now monitor the designated Inbox and
kick off the Hardware request workflow when a qualifying e-mail
Does it work?
To test the workflow and make sure it is working, send an e-mail
to the e-mail account you will be monitoring. Make sure it matches
the expected content criteria you set up in the event listener. If
everything has been set up correctly, the workflow should be
initiated by the e-mail you sent. To confirm, check to see whether
the designated approver received the approval request.