Micro Focus QTP (UFT) Forums
How to pause QTP script using DotNet Factory - 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: VB Scripting/Descriptive Programming (https://www.learnqtp.com/forums/Forum-VB-Scripting-Descriptive-Programming)
+--- Thread: How to pause QTP script using DotNet Factory (/Thread-How-to-pause-QTP-script-using-DotNet-Factory)



How to pause QTP script using DotNet Factory - nistalaramesh - 01-30-2011

I have a QTP script in that after executing some keywords i have to pause the script and i have to to some manual steps later on i want to continue.
But here the wait time is unknown.
I want to call a Custom form in that it should contain 2 buttons
1) Pause the QTP Test
2) Resume the QTP Test

Once i click the button "Pause the QTP Test" the script should get pause
then i want to perform other manual things
Once it is complete then
I want to click 2nd Button "Resume the QTP Test" my script should proceed further.
I went through "Part3: QTP and DotNetFactory......." I created form & Buttons.

But i don't know what to write to Pause & Resume the script.

Can Anyone help me in this?


RE: How to pause QTP script using DotNet Factory - nistalaramesh - 02-19-2011

Hi Ankur,
Can you please provide help on this?


RE: How to pause QTP script using DotNet Factory - Imran - 06-23-2011

Code:
Dim App
Set App = CreateObject("QuickTest.Application")
App.Test.pause
App.Test.Run



RE: How to pause QTP script using DotNet Factory - Saket - 06-23-2011

Hi nistalaramesh,
first thing - why do you need such kind of thing when we already have built in feature to stop, pause or resume in QTP?
in any case if you want this form with the two button to be running side side while your script execution is going on, in that case, this wont be possible using DotNet Factory as we can not create or assign methods/action for controls in the form created as we have in visual basic.

refer - QTP and DotNetFactory Series