While spliting an action in QTP 10.0 getting an error :
"This Line is a part of Script Block.You cannot split the
action on this line." how to re-solve this and split the
script into actions?
Answer / Ranjeet Kumar Chanchal
The error occurs when attempting to split a QTP action that contains multiple lines of code into separate actions. To resolve this issue, you can do the following:
1. Create a new test module or test case.
2. Copy the entire script block (including the problematic line) and paste it into the new test case.
3. Split the script into separate actions as desired.
4. Test the newly created test case to verify functionality.
| Is This Answer Correct ? | 0 Yes | 0 No |
why text area checkpoints cannot used for web applications
How you automate test scripts
Hi All Below is my script which i made for lgin into Flight.exe. SystemUtil.Run "C:\Program Files\Mercury Interactive\QuickTest Professional\samples\flight\app\flight4a.exe","","C:\Program Files\Mercury Interactive\QuickTest Professional\samples\flight\app\","open" Dialog("Login").WinEdit("Agent Name:").Set DataTable ("p_Text", dtGlobalSheet) Dialog("Login").WinEdit("Agent Name:").Type micTab Dialog("Login").WinEdit("Password:").SetSecure DataTable ("p_Text1", dtGlobalSheet) Dialog("Login").WinButton("OK").Click If Dialog("Login").Dialog("Flight Reservations").WinButton ("OK").exist Then Dialog("Login").Dialog("Flight Reservations").WinButton ("OK").Click datatable.Value(3)= "Incorrect password. Please try again" Dialog("Login").WinButton("CANCEL").Click elseif Dialog("Login").Dialog("Flight Reservations").WinButton("OK").exist Then Dialog("Login").Dialog("Flight Reservations").WinButton("OK").Click datatable.Value(3)="Please enter agent name" Dialog ("Login").WinButton("CANCEL").Click elseif Dialog("Login").Dialog("Flight Reservations").WinButton("OK").exist then Dialog("Login").Dialog("Flight Reservations").WinButton("OK").Click datatable.Value(3)= "Please enter password" Dialog("Login").WinButton ("CANCEL").Click else Window("Flight Reservation").Move 309,146 datatable.ExportSheet "C:\Raj\Result.xls" ,1 Window("Flight Reservation").Close End If I want to capture the Message string from Dialog("Login").Dialog("Flight Reservations" Also pls let me know if this is the right way to do the script for login. Pls provide some script for login Flight.exe Thanks in advance Raj Dhiman
I want to scroll down in MSPAINT (captured a screen already). So that I can read the data in it through the step Window(paint).GetVisibleText for my validation. Anyone know the scripting for this?
How to test the mandatory fields in QTP?
How to capture a window in QTP?
For Regression testing already written test cases are sufficient?
How do we create and run the scripts with out using O.R. ?
explain how to write vb script in qtp?when will you write own script?
When can shared object repository fails?
How to face prjoect manager round what type of questions they will Ask ? (Chandana)
1 Answers Call Centre, Convergys, IBM,
wat are views in qtp explain