Micro Focus QTP (UFT) Forums
How to stop Second Action Call - Printable Version

+- Micro Focus QTP (UFT) Forums (https://www.learnqtp.com/forums)
+-- Forum: Micro Focus UFT (earlier known as QTP) (https://www.learnqtp.com/forums/Forum-Micro-Focus-UFT-earlier-known-as-QTP)
+--- Forum: UFT / QTP Beginners (https://www.learnqtp.com/forums/Forum-UFT-QTP-Beginners)
+--- Thread: How to stop Second Action Call (/Thread-How-to-stop-Second-Action-Call)



How to stop Second Action Call - faheem05 - 10-04-2012

Hi,
In My script I have two Actions say:
Action1
Action2
By default both the action code executes as we run the script. But I dont want to run the Action2 based on some condition I am checking in Action1.
Could we do that.. Please help..
Thanks In Advance.


RE: How to stop Second Action Call - Sathiya - 10-04-2012

tried with if statement?


RE: How to stop Second Action Call - sshukla12 - 10-04-2012

Hi,

Use if statement and if ur condition meets then go for LoadAndRunAction statement.

Regards,
Sankalp


RE: How to stop Second Action Call - faheem05 - 10-04-2012

Thank for reply..
I am using the IF condition for running Action2 but my problem is at the end to Action 1 execution automatically it switches to Action2 execution which I dont want it...
let me know how can i stop this execution..


RE: How to stop Second Action Call - sshukla12 - 10-04-2012

Hi,

Are you calling action 2 from Action 1 or these 2 actions are called independently from one driver script?


Regards,
Sankalp


RE: How to stop Second Action Call - Jenny - 10-05-2012

hi, make your action 2 a resuasable aciton, then delete it from test flow. so still see action 2 from resources and can call from your if.... call action 2


RE: How to stop Second Action Call - faheem05 - 10-05-2012

Hi, Thanks alot..
after deleting from Test Flow it works as I was expecting..

regards,
Faheem