How to correct the action flow in Script when the actions are executed based on driver script?

As we tend to run the actions in UFT/QTP by our driver script based on the flag set in the excel sheet or any input file, we don't want the flow in the solution to interrupt the execution.

As the new concept of solution comes in the UFT, whenever you add any new action it gets added in the flow of the solution sequentially. For e.g. you have an existing action "Action1" and then you create a new Action with name "Action2". So in the flow the Action2 will be added after Action1 and as soon as the execution of Action1 completes Action2 will get executed.




But we want the execution of actions should be derived from the driver script, So we need to remove the Action2 from the solution flow. If you try to do it directly from the solution then there is only one option "Delete Action".

The workaround to remove this call is, you have to first call the Action2 from some other Action also and then delete the actions call from the solution flow as shown in below images. And then remove the action call line (Runaction "Action2") from Action1.





This needs to be done for every new action you add to the UFT test and don't want to execute as per the solution flow.

Comments

Popular posts from this blog

UFT - Resolving scrolling issue if object is not visible

How to create a zip folder using VBScript

how to access the excel file as database in UFT?