![]() |
| |||||||
Automation Anywhere Post messages and questions related to Automation Software here. |
![]() |
| | LinkBack | Thread Tools | Display Modes |
| |||
|
Hi, I have 6 error handlers inside a loop in a task, loop iterates 6 times, if there is an error in error handler 2 or error handler 5 then I need to exit the current iteration and jump to the next iteration or else continue in the same iteration of the main loop. At the same time we need to have a log file having all error description that has taken place during the 6 iteration. Can we achieve this simple thing with AA in a simple manner? Note: We can;t keep a separate text file to log for each error handler to log. Last edited by rahul; 02-12-2009 at 11:37 AM. |
| |||
|
Hello, Yes, it can be done with Automation Anywhere. If there is an error in error handler 2 or error handler 5 then you can assign a value to a user variable that reads value from a text file. After 2nd and 5th error handler block you can check the value of user variable using 'If Variable' command. If condition is true i.e. if error is present then insert 'Continue' option of Loop command to jump to the next iteration. We have attached a sample task for your reference. This task would jump to the next iteration if there is an error in error handler 2 or error handler 5. You can see all the errors logged in ErrorFlow.txt at the end of task. To run this task, . Please copy attached task under location, 'C:\...\My Documents\Automation Anywhere\Automation Anywhere\My Tasks' folder. . Before running this task, please create a variable, GlobalVar that reads value from a text file. To create a variable that read from text file, please follow below mentioned steps: 1. Go to Tools->Variable Manager in Automation Anywhere. 2. Click on 'Add New Variable'. 3. In 'Name' field, enter variable name i.e. GlobalVar. 4. Select 'Read from text file' radio button or option. 5. In 'Value' field, specify the path of text file i.e c:\Abc.txt. 6. Press 'Save' button. 7. Press 'Ok' button. Note: Variables are case-sensitive. Hope that helps. |
![]() |
| Thread Tools | |
| Display Modes | |
| |