Drawing activity diagrams

Activity diagram is a flowchart-based diagram showing flow of control from activity to activity. It shows concurrency, branch, control flow and object flow. Swimlane, furthermore, is used for partitioning the activity states.

Creating activity diagram

  • Click on UML on toolbar and select Activity Diagram from the drop down menu.
  • Right click on Activity Diagram in Diagram Navigator and select New Activity Diagram from the popup menu.
  • Select File > New Diagram > UML Diagrams > Activity Diagram from the main menu.
Create activity diagram
Create activity diagram

Creating swimlane

You can click either Horizontal Swimlane or Vertical Swimlane on the diagram toolbar.

Create swimlane
Create swimlane

Click on the diagram to create the swimlane.

Swimlane created
Swimlane created

Double-click the partition name to rename it.

Rename partition
Rename partition

Inserting partition to swimlane

To insert partition to swimlane, right-click on a partition and select either Insert Partition Before or Insert Partition After from the pop-up menu.

Insert partition to swimlane
Insert partition to swimlane

A partition is inserted.

Partition inserted
Partition inserted

Creating initial node

Click Initial Node on the diagram toolbar.

Create initial node
Create initial node

Click inside the partition to create the initial node there.

Initial node created
Initial node created

Creating action

Mouse over the initial node until its resources are visible. Click on the Control Flow -> Action resource and drag.

Create action
Create action

Move the mouse to where you want to place the action to, and then release the mouse button. An action is created and is connected to the initial node with a control flow.

Action created
Action created

Similarly you can create a new action using the Control Flow -> Action resource of an action.

Create a new action from an action
Create a new action from an action

A new action is created and is connected to the action with a control flow.

Action created
Action created

Continue to complete the activity diagram.

Completed activity diagram
Completed activity diagram

Working with scenario

A scenario is a diagram formed by the internal interaction of a sequence of action, modeled by their sub-diagrams. With scenario, you can produce a diagram which presents an overview of an execution path in activity diagram, so as to know how user and system communicate with each other in order to complete the flow.

Producing scenario from activity diagram

  1. Right click on the activity diagram that contains the flows that you want to produce a scenario, and select Scenarios > Edit Scenarios... from the popup menu.
    Edit scenarios
    Edit scenarios
  2. In the Edit Scenarios dialog box, click Add... button at the bottom left corner.
  3. Select a path for generating scenario. Click OK to confirm.
    Select a path for generating scenario
    Select a path for generating scenario
    NOTE: A path is a continuous flow of actions in the diagram, with an initial node placed at the beginning of the actions. Multiple paths are obtained by determining the existence of decision nodes within the flow.
  4. Name the scenario. Add description if necessary.
    Name and describe scenario
    Name and describe scenario
  5. The actions being involved in the flow are listed in the Path table. For actions that have sub-diagram(s), pick up the sub-diagram in Diagram column, or just create a new one. You may, however, leave it unspecified, which cause that action to be ignored when producing scenario.
    Select diagram for action
    Select diagram for action
  6. Click on the arrow beside the Generate button and select the type of diagram of the scenario.
    Generate scenario with specific diagram type
    Generate scenario with specific diagram type

Updating scenario

Whenever the sub-diagram(s) of action(s) are updated, you can update the scenario to make it represents the latest information of interaction. To update scenario, right click on the activity diagram that have scenario produced before, select Scenarios, then the name of scenario from the popup menu.

 
Chapter 2. Behavioral Modeling Table of Contents 2. Drawing state machine diagrams
 

Product

Try this feature with

Visual Paradigm for UML

Technical Support

Have technical issues or suggestions? Please contact Visual Paradigm Support Team.

Sales Support

Have questions related to registration, licensing or payment? Feel free to contact Visual Paradigm Sales Team.

Discussion Forum

Share your suggestions of opinions at VP Discussion Forum.