Before you start designing an automation project, create a diagram of the manual process you want to automate, breaking it down into each of the steps it consists of. This helps you identify the sequence of activities that are required to automate it.
- Base new projects on project templates, fully working automation projects for common processes.
- Use common scenarios, reusable pieces of automation for common tasks, to add multiple activities at once.
- Use the App/Web Recorder to automatically generate UI automation activities from the actions you perform on screen.
Use the dedicated activities when working with Excel, Mail, Word, and PowerPoint data, and when performing file and folder operations. For interactions with all other applications, use UI automation activities.
Using names that describe the purpose of each component makes it easier to identify them, especially when the same type of component is used multiple times. This applies to project names, activity names, Reference as names of resources added to the project (Excel and PowerPoint files, email accounts), names of the current item in the iteration inside For each activities (by default CurrentRow, CurrentMail, CurrentFile), and names of values that you save for later use in the automation.
Document the activities in your project by adding annotations with information about what they do. This is especially important if you plan to share automation projects with others, as it helps them understand how the automation works. To add an annotation to an activity, right-click the activity, and then select Annotations > Add annotation.
- Analyze your project by running the Workflow Analyzer. This checks for errors in how activities are configured and verifies that the project follows design guidelines defined through Workflow Analyzer rules. Click Analyze in the StudioX ribbon and view the results of the analysis in the Error List panel. For more information, see About Workflow Analyzer.
- Run your project and check if the results are the expected ones. The more often you run the automation, the easier it is to identify potential problem spots.
- If an error occurs when you run a project, pay attention to the error message, it can contain valuable information about the cause of the error and ways you can fix it. Use the options in the error dialog to retry the activity which generated the error, skip to the next activity or item, or stop execution.
- Stop execution at or start execution from a certain point in the project. Right-click any activity and select:
- Run to this Activity to execute all the activities in the project up to (and including) the activity.
- Run from this Activity to execute all the activities in the project starting with the activity.
- Disable individual activities that may be causing errors and execute the project without them. You can disable an activity by right-clicking it and selecting Disable Activity. Disabled activities appear dimmed and surrounded in a Comment Out container in your project diagram. To re-enable a disabled activity, right-click the Comment Out container and select Enable Activity.
Messages placed at certain points in the workflow help you follow the progress of the project and provide information about the outcome of other activities. You can display messages using the following activities:
- Write Line displays messages in the Output panel without interrupting the execution of the project.
For example, when repeating activities for each row in an Excel file, add a Write Line activity as the first activity inside For Each Excel Row and configure it to display a message that includes the contents of a cell from each row. You can indicate the cell by selecting the column from the CurrentRow option in the menu available in the Text Builder. Generating a message whenever the automation begins processing a row allows you to check whether the rows are processed as expected.
- Message Box displays a dialog box with a message, pausing the execution of the automation project until a button is clicked in the dialog box.
For example, after the last of the activities that manipulate data in a Word file, add a Message Box activity that displays the message "The Word document has been processed". This gives you confirmation that the Word activities completed and the automation can move to the next activities.
When you finish designing the project, remove these activities before publishing it.
- Do not add credentials directly to your projects. Use the Get Username/Password activity that enables you to add credentials to your project and store them securely in the Windows Credential Manager.
- Do not store files with sensitive data in the project folder, especially if you plan to share your automations with others. By default, when you publish an automation, all the files in the project folder are included in the package.
Updated 5 months ago