SlideShare a Scribd company logo
Website: http://www.ITeLearn.com
Email : learn@itelearn.com
Contact: +1-314-827-5272,
+91-837-4323-742(India)
QTP Interview Questions and Answers
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
1. What is the output on the print screen when this code gets executed? (Please try without
using QTP or a VB Script executor).
Dim vString, vInt
vInt = "Hello"
vString = 25
print vInt + vString
a. RunTime Error
Hint: Occurs during the running of the script.
b. Hello25
c. Cannot add String and Integer using "+" sign
d. Syntax Error
Hint: Error in writing our code correctly.
e. vIntvString
Ans: b
Chapter: 1 Topic: Video1
1. Which tests is the better candidate for Automation
a. Test Cases that is easy to Automate
b. Test cases that are repeatedly executed manually which will have a greater Return on
Investment (ROI)
c. Adhoc Tests
d. Exploratory Tests
e. All of the above
Ans: b
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
2. Primary goal of test automation is
a. To reduce the testing project's effort
b. To reduce the number of tests to be run manually
c. Eliminate manual testing
d. Faster release cycles
e. All of the above
Ans: b
3. Framework Analysis and recommendations for improvements are done during the
a. Automation Test Strategy phase
b. Design phase
c. Build phase
d. Both 1 and 2
e. Only 3
Ans: a
4. In QTP, the ______________ provides the snap shot / screen shot of the application as it
appeared during the recording session.
a. Expert View
b. Keyword View
c. Active Screen
d. Record and Run Settings
e. Actions
Ans: c
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
5. What is the Syntax for instructing QTP to wait for 5 seconds between two steps?
a. object.Wait(5)
b. delay(5)
c. timer(5)
d. wait(5)
e. Sync(5)
Ans: d
6. What is the Navigation path for Accessing "Record and Run Settings"?
a. File ==> Test ==> Record and Run Settings
b. View ==> Record and Run Settings
c. Resources => Record and Run Settings
d. Tools => Record and Run Settings
e. Automation ==> Record and Run Settings
Ans: e
7. What are the Recording Modes Available in QTP?
a. (1) Web Based
(2) Windows Based
b. (1) Functional
(2) Non Functional
c. (1) Context Sensitive/ Normal Recording Mode
(2) Analog Recording Mode
(3) Low Level Recording
d. (1) Keyboard Recording Mode
(2) Mouse Recording Mode
Ans: c
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
8. Which is the Default Recording Mode in QTP?
a. Context Sensitive
b. Analog Recording Mode
c. Low Level Recording
d. Keyboard Recording Mode
e. None of the above
Ans: a
9. Which Recording Mode Records mouse clicks with co-ordinates?
a. Analog Recording Mode
b. Low Level Recording
c. Context Sensitive
d. Both 1 and 2
e. All the Above
Ans: b
10. Which of the following DOESNOT record Object Information while recording
a. Analog Recording Mode
b. Low Level Recording
c. Context Sensitive
d. Both 1 and 2
e. None of the above
Ans: a
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
11. Which of the following recording modes DOESNOT Allow user to EDIT scripts after
Recording?
a. Low Level Recording
b. Context Sensitive
c. Analog Recording Mode
d. Both 1 and 3
e. None of the above
Ans: c
12. How to make QTP to show the Results of the Test immediately after the Test Script
Execution
a. File -> settings-> Run
b. Tools ==> Options ==> Run
c. View ==> Test Results
d. Automation ==> Settings ==> Run
e. There is no such feature available in QTP to show the results automatically.
Ans: b
Chapter: 1 Topic: Video2
13. What are the Default set of add-ins installed automatically with Quick Test Pro
Installation?
a. (1) Active X, VB, .NET
b. (2) Active X, Java, Web
c. (3) Active X, Java, VB
d. (4) Active X, VB, Web
e. (5) Active X, .NET, Java, VB, Web
Ans: d
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
14. How the Test Set in QTP is saved?
a. .vbs
b. .tsr
c. .qfl
d. quick test tests
e. None of the above
Ans: d
15. How to comment a line in VB Scripting?
a. A comment should commence with a Single Quote or "REM"
b. Statement should start with the keyword
c. A single Comma
d. It should start with /* and end with */
e. Statement should start with *
Ans: a
16. What is the Short cut for commenting and Uncommenting an existing line of Code?
a. (1) Ctrl + M for Commenting
(2) Shift + Ctrl + M for UnCommenting
b. (1) ALT + M for Commenting
(2) ALT + Ctrl + M for UnCommenting
c. (1) Shift + M for Commenting
(2) Alt + Shift + M for UnCommenting
d. (1) Shift + Ctrl + M for Commenting
(2) Ctrl + M for Uncommenting
e. None of the above
Ans: a
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
17. ________________ is used for executing a single statement if that statement is a
function call or action call then it will step onto that function or action
a. Step onto
b. Step over
c. Step into
d. step out
e. None of the above
Ans: c
18. ___________ is used for executing all the remaining statement in that in that function
call or action from the position of pointer
a. Step onto
b. Step over
c. Step into
d. Step Out
Ans: d
19. ____________ is used for executing a single statement if that statement is a function
call or action call then it will execute the complete block of statements once present in the
function/action
a. Step onto
b. Step over
c. Step into
d. Step Out
Ans: b
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
20. Shortcuts for Step into, Step over and Step out
a. (1) Step Into F11
(2) Step Over F10
(3) Step Out SHIFT + F11
b. (1) Step Over F11
(2) Step Into F10
(3) Step Out SHIFT + F11
c. (1) Step Out F11
(2) Step Into F10
(3) Step Over SHIFT + F11
d. (1) Step Into F10
(2) Step Over F11
(3) Step Out SHIFT + F11
Ans:a
21. How a user can insert a Break Point
a. By Pressing "F9" after keeping the focus on the statement where the user wants the
Break point
b. Debug => Insert/Remove Breakpoint
c. The breakpoint can be inserted by just clicking on the left margin of the executable
statement
d. All the Above
Ans: d
22. Break Points are saved with the QTP Tests/Function Libraries
a. True
b. FALSE
Ans: b
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
23. What is the Short cut to remove all Break points?
a. Ctrl + F9
b. Shift + Ctrl+ F9
c. Alt + Ctrl+ F9
d. Shift + F9
e. all of the above
Ans: b
24. User will be able to add break points when the window session is in "Break" Mode
a. True
b. FALSE
Ans: b
25. What does a break point do?
a. Stops test execution at the specified step, after executing that step
b. Stops test execution at the specified step, before executing that step.
c. Pauses test execution at the specified step, after executing that step
d. Pauses test execution at the specified step, before executing that step.
e. all of the above
Ans:d
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
26. Which method is used to enter a text in a text box/web edit?
a. obj.SetText "ABC"
b. obj.SetValue "ABC"
c. obj.Set "ABC"
d. obj.Enter "ABC"
Ans: c
27. Which of the following method is used to select a value from a list box
a. obj.SelectValue "ABC"
b. obj.Select "ABC"
c. obj.ListSelect "ABC"
d. obj.SelectListValue "ABC"
Ans: b
28. Which of the following method is used to perform a click on a object
a. Obj.Click
b. Obj.Activate
c. Obj.Mouseclick
d. Obj.PerformClick
Ans: a
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
Chapter: 1 Topic: Video3
29. How QTP identity objects
a. QTP can recognise any object without knowing any description of the object
b. QTP uses the learned description to identify objects
c. QTP stores the object properties while recording and on playback, uses the learned
properties to identify
d. Both (2) and (3)
e. None of the above
Ans: c
30. What is object repository?
a. A file where QTP stores Actions
b. A file where QTP stores scripts
c. A file where QTP stores Run Time objects
d. A file where QTP stores Test Objects
e. All of the above
Ans: d
31. What are the types of object repository?
a. Only Local
b. Only Shared
c. Local and Shared
d. There are no Local or Shared object repositories
Ans: c
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
32. What is child object?
a. There is no child object concept
b. Object contained within the another object
c. Child Objects is a method
d. All of the above
Ans: b
33. In which hierarchy QTP stores objects in Object Repository
a. QTP stores objects form Parent to child hierarchy
b. QTP stores only Child objects
c. QTP stores only Parent objects
d. QTP does not store any object
Ans: a
34. QTP can store objects in object repository only on recording
a. TRUE
b. FALSE
c. May be
d. None of the above
Ans: b
35. What is Active Screen?
a. Where the script is generated
b. Where object is stored
c. It is Keyword view where steps are displayed
d. Active screen provides the snap shot or screen shot of the application
e. None of the above
Ans: d
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
36. What is checkpoint in QTP?
a. Used to debug script
b. Work same as Breakpoint
c. Checkpoint is a verification point
d. Checkpoint is method
e. All of the above
Ans: c
37. What is variable in terms of vbscript
a. Variables are used to hold values or expressions
b. Variables are used to store objects
c. Variables are used to store actions
d. All of the above
Ans: a
38. Types of variables in vbscript
a. Variant
b. Only Boolean
c. Only Integer
d. There are different kind of variables like Integer, Boolean, Long, Double etc
Ans: a
39. File extension for local and shared object repository
a. .mtr and .bdb
b. .bdb and .tsr
c. Only .bdb
d. Only .tsr
e. None of the above
Ans: b
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
40. Can we change logical names of the object in OR
a. Cannot be changed
b. No
c. Yes
d. None of the above
Ans: c
Chapter: 1 Topic: Video4
41. What is Syntax error in script?
a. Syntax error is a grammatical error
b. A syntax error in programming where the code that is written by a programmer which is
incorrect as per the language structure
c. Syntax error is logical error in script
d. There are no such types of error
Ans: b
42. In QTP where you can provide URL and launch your application
a. In Settings option
b. Tools -> Options
c. Automation -> Record and Run Settings
d. Both (1) and (2)
Ans: c
43. What does SystemUtil.Run do
a. It starts test execution
b. It invokes the QTP
c. It opens browser with mercury website URL
d. SystemUtil.Run is an inbuilt QTP command that lets you run a file or an application
e. All of the above
Ans: d
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
44. How you can add objects in OR
a. Object can be added using Add Object button in OR
b. Object can be added using drag and drop
c. Objects cannot be added to OR
d. Record some actions on the object; this will automatically add this object to the object
repository
e. None of the above
Ans: a and d
45. What are conditional statements?
a. Conditional statements are used to execute same block of code for a specified number of
times
b. Conditional statements are used to perform different actions for different decisions
c. Comments in VbScript knows as conditional statements
d. You can control the flow of your script with conditional statements
e. Both (b) and (d)
Ans: e
46. What is "For Next" loop in vbscript?
a. A conditional statement
b. A type of variable in VbScript
c. Looping statements are used to run the same block of code for a specified number of
times
d. Both (1) and (2)
e. All of the above
Ans: c
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
47. What is the Syntax of "For Next" loop in vbscript?
a. For i to n
b. For i = 0 to n
c. For i = 0 to n
Next
d. For i = 0 to n Step 2
Next
e. All of the above
Ans: c & d
Chapter: 1 Topic: Video5
48. What is Dim statement in vbscript?
a. To declare only Integer data types
b. Declares and allocates storage space for one or more variables
c. It is a variable type in vbscript
d. It is a conditional statement
e. None of the above
Ans: b
49. How to declare a variable in vbscript?
a. Int i
b. String i
c. Dim i
d. ReDim i
e. All of the above
Ans: c
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
50. You have a variable i, Define it correctly with any value
a. Dim i
b. i
c. Dim i = 10
d. i = 10
e. all of the above
Ans: c
51. What is Option Explicit statement in vbscript?
a. Used at script level to force explicit declaration of all variables in that script
b. Used to declare a variable
c. It forces you to declare all of your global variables
d. It forces you to call the method
e. It forces you to declare all of your static variables
Ans: a
52. Find the variable which is defined as a Integer
a. Dim a = "abc"
b. Dim a = 10
c. DIm a = 10.50
d. TRUE
e. All of the above
Ans: b
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
53. Find the variable which is defined as a String
a. Dim a = "abc"
b. Dim a = 10
c. DIm a = 10.50
d. FALSE
e. All of the above
Ans: a
54. Find the variable which is defined as a Float
a. Dim a = "abc"
b. Dim a = 10
c. DIm a = 10.50
d. TRUE
e. All of the above
Ans: c
55. What are different types operators available in vbscript?
a. Only Arithmetic
b. Only Logical
c. Only Comparison
d. Arithmetic Comparison Logical
Ans: d
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
56. Concatenate two strings "Welcome to" and "IteLearn.com"
a. "Welcome to" + "IteLearn.com"
b. "Welcome to" ++ "IteLearn.com"
c. "Welcome to" & "IteLearn.com"
d. "Welcome to" && "IteLearn.com"
e. All of the above
Ans: c
57. In which expression Addition operator is used correctly
a. 3 + 5
b. 3 ++ 5
c. 3 & 5
d. 3 && 5
e. None of the above
Ans: a
58. What is the function of Modulus operator (Mod)?
a. Divides two numbers and returns the integer part
b. Divides two numbers and returns only the remainder
c. Divides two numbers and returns the decimal part
d. Divides two numbers and returns the result
Ans:b
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
Chapter: 1 Topic: Video6
59. Which method will you use to get any property value of an Object at run time?
a. By GetROProperty
b. By GetTOProperty
c. By SetROProperty
d. By SetTOProperty
e. All of the above
Ans: a
60. What is GetROProperty method?
a. Method to retrieve the current value of an identification property from a test object in
your application
b. Method to Set value of an identification property of a run-time object in your application
c. Method to retrieve the current value of an identification property from a run-time object
in your application
d. Method to retrieve the property of an identification property from a run-time in your
application
Ans: c
61. Where you can use GetTOProperty method?
a. Method enables you to retrieve a specific property and value that QTP uses to identify an
object.
b. Method enables you to set a specific property value of that QTP uses to identify an
object.
c. Method to retrieve the current value of an identification property from a run-time object
in your application
d. Both b and c
Ans: a
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
62. What is use of SetTOProperty method in QTP?
a. Method to retrieve the current value of an identification property from a run-time object
in your application
b. Method to retrieve the property of an identification property from a run-time in your
application
c. Method enables you to retrieve a specific property and value that QTP uses to identify an
object.
d. Method enables you to modify a property value that QTP uses to identify an object
Ans: d
Chapter: 2 Topic: Actions
63. Actions call can be added to a test during ____ in QTP.
a. Recording
b. Designing
c. Editing
d. All of the above
e. None of the above
Ans: b
64. When you create a new test in QTP, it contains ___.
a. Multiple Actions
b. Single Action
c. All of the above
d. None of the above
Ans: b
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
65. Which action you can insert in your current test in QTP?
a. Stored in current test
b. Stored within an another test
c. All of the above
d. None of the above
Ans: c
66. For every action QTP creates a corresponding action sheet in the Data Table. Is this
statement correct?
a. No
b. Yes
c. None of the above
Ans: b
67. What you can choose to view after opening the test?
a. Test flow (calls to actions)
b. View and edit the individual actions stored with your test.
c. Both A & B
d. None of the above
Ans: c
68. For every action called in your test, QuickTest creates a corresponding ........ in the Data
Table so that you can enter Data Table parameters that are specific to that action only.
a. Action sheet
b. Excel sheet
c. Both A & B
d. None of the above
Ans: a
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
69. What are the types of Actions in QTP?
A. Non-reuse action, Reuse action, External action
b. Call to internal action, Call to reusable action, external action
c. Non-reusable action, Reusable action, External action
d. Call to non-reusable action, reusable action, external action
Ans: c
70. By default, new actions are ___
a. Short
b. External
c. Reusable
d. Non-reusable
Ans: d
71. You can display or hide the Action toolbar in the Keyword View by choosing ........
a. View > Toolbars > Action
b. View > Toolbars > Actions
c. View > Toolbar > Action
d. Views > Toolbars > Action
Ans: a
72. The ...... enables you to view either the entire test flow or you can view the steps for a
selected reusable or external action
a. Action Flow
b. Action file
c. Action List
d. Action Repository
Ans: c
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
73. In the ......., the Action List is always visible and the Expert View always displays the
script for the selected action
a. Keyword View
b. Expert View
c. Action Flow
d. Action View
Ans: b
74. If the action is called more than once within the test flow or if the action is called by a
reusable action, the Reusable action option is.....
a. read-only
b. write-only
c. both read and write
d. read-write-executable
Ans: a
75. You cannot expand ...... actions from the test flow view
a. reusable
b. non-reusable
c. both A & B
d. None of the above
Ans: a
76. You can associate shared object repositories with ...... actions simultaneously, using
the Associate Repositories dialog box
a. seven
b. Two
c. Three
d. Multiple
Ans: d
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
77. You can associate ....... object repositories with an action, and the same object
repository can be associated with different actions as needed
a. Nine
b.Twenty one
c. as many as you need
d. Twelve
Ans: c
78. Sometimes you may want to call an action from within an action. This is called.......
a. Reusability
b. Nesting
c. Sharing
d. None of the above
Ans: b
79. You must use the...... Action option in QuickTest if you want to save an action under
another name
a. Resave
b. Rename
c. Reuse
d. Split
Ans: b
80. You can also press ...... to open the Rename Action dialog box
a. Shift + F2
b. Shift + F3
c. Shift + F4
d. Shift + F5
Ans: a
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
81. If you want to include one or more statements in every new action in your test, you can
create an....
a. reusable action
b. split action
c. Function
d. action template
Ans: d
82. Only the file name ...... is recognized as an action template
a. ActionTemplate.mst
b. Action_Template.mst
c. Action-Template.mst
d. ActionTemplates.mst
Ans: a
Chapter: 2 Topic: Checkpoints
83. The ........checks a variety of objects such as buttons, radio buttons, combo boxes, lists,
and so forth
a. Image checkpoint
b. Standard checkpoint
c. Bitmap checkpoint
d. Accessibility checkpoint
Ans: b
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
84. You create an image checkpoint by inserting a........ on an image object
a. Image checkpoint
b. standard checkpoint
c. Bitmap checkpoint
d. Accessibility checkpoint
Ans: b
85. ......... are also supported for some list view objects, such as WinListView and
VbListView, as well as other list view objects in external add-in environments
a. Table checkpoints
b. standard checkpoints
c. Accessibility checkpoints
d. XML checkpoints
Ans: a
86. ........Specifies the time interval (in seconds) during which QuickTest attempts to
perform the checkpoint successfully
a. Check timeout
b. Checkpoint interval timeout
c. Checkpoint timeout
d. Quicktest timeout
Ans: c
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
87. You can view the results of the checkpoint in the........
a. Test Results window
b. Checkpoint window
c. Information Pane
d. Checklist window
Ans: a
88. By default, the bottom right part of the Test Results window displays information on the
selected checkpoint only if it has the status Failed
a. TRUE
b. FALSE
Ans: a
89. You can also use the ......... to check specific property values
a. Check Property method
b. Check Item Property method
c. Item Property method
d. Property method
Ans: a
90. If you want to retrieve the return value of a checkpoint (a boolean value that indicates
whether the checkpoint passed or failed), you must add ......... the checkpoint argument in
the statement in the Expert View.
a. parentheses around
b. Properties with
c. Arguments with
d. Values along with
Ans: a
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
91. You can use a formula in a checkpoint to confirm that an object created on-the-fly
(dynamically generated) or another variable object in your Web page or application
contains the value it should for a given context.
a. TRUE
b. FALSE
Ans: a
92. You cannot modify the settings of existing checkpoints
a. TRUE
b. FALSE
Ans: b
Chapter: 3
93. What is Function in vbscript?
a. Does not returns a value to the code that calls it
b. Returns a value to the code that calls it
c. Same as Procedure
d. All of the above
Ans: b
94. What is Procedure or Subroutine in vbscript?
a. Returns a value to the code that calls it
b. There is no difference between functions and subroutine
c. does not returns a value to the code that calls it
d. None of the above
Ans: c
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
95. You use Exit ____ to exit a Do...While...Loop statement
a. Do
b. While
c. Only Exit
d. Loop
e. All of the above
Ans: a
96. Which statement to force user to explicitly declare variables?
a. Explicit
b. Option
c. No such statement required
d. Option Explicit
Ans: d
97. A = True, B = True ---> A And B = ?
a. TRUE
b. FALSE
c. None of the above
Ans: a
98. Dim Arr()
Msgbox Arr(2)
What will be the result?
a. 1
b. 2
c. 0
d. Error message
Ans: d
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
99. We use the _____ statement to declare a variable
a, ReDim
b. Option Explicit
c. Dim
d. Preserve
e. None of the above
Ans: c
100. How to get size of any Array?
a. LBound (Arr)
b. UBound (Arr)
c. Len(Arr)
d. UBound(Arr) - LBound(Arr)
e. All of the above
Ans: d
101. Is VbScript is Case sensitive or case insensitive?
a. Case Insensitive
b. Case sensitive
Ans: a
102. By Default in vbscript the argument passed to function or sub routine is _____
a. By Reference
b. By Value
Ans: a
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
103. How to declare an Array in vbscript?
a. Arr(4)
b. Dim Arr() OR
Dim Arr(5)
c. ReDim Arr
d. Dim Arr
e. All of the above
Ans: b
104. What is Dictionary Object in vbscript?
a. Same as Array
b. Stores only Item
c. Stores key / item pair
d. Stores only Key
e. None of the above
Ans: c
105. Which function allows to instantiate an object in vbscript?
a. Create Object
b. Dim
c. Set
d. Object
e. All of the above
Ans: a
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
106. What is the purpose of On Error Resume Next statement in vbscript?
a. Stops execution whenever any error occurred
b. Print Error number
c. Print Error description
d. causes execution to continue with the statement immediately following the statement
that caused the run-time error
e. None of the above
Ans: d
107. How to declare a Class in vbscript?
a. Dim Class
b. Class name
Statements
End Class
c. CreateObject Class
d. Class name
Statements
End
e. None of the above
Ans: b
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
108. What are the conditional statements in vbscript?
A. Only If
b. Only Select Case
c. If...
If...Then...Else
If...Then...Else If
Select Case
d. If...
If...Then...Else
If...Then...Else If
e. None of the above
Ans: c
109. What is parameterization in vbscript?
a. Checking the same operations with multiple sets of data
b. Passing Constant values
c. Passing fixed values
d. None of the above
Ans: a
110. What is the use of ReDim statement in vbscript?
a. The ReDim statement is used to size or resize a Static array that has already been
formally declared using Dim
b. The ReDim statement is used to size or resize a Dynamic array that has already been
formally declared using Dim
c. Used to declare a variable
d. None of the above
Ans: b
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
111. _____ arrays can be handled by vbscript.
a. Only Static
b. Only Dynamic
c. Both Static and Dynamic
d. All
Ans: c
112. What is the syntax to find length of any string?
a. Len (string)
b. Size (string)
c. Ubound(string)
d. Lbound(string)
e. None of the above
Ans: a
113. How to convert any string to upper case?
a. LCase(string)
b. Uppercase(string)
c. Lowercase(string)
d. UCase(string)
Ans: d
114. How to access first element of array?
a. Arr(0)
b. Arr(1)
c. Arr(2)
d. Arr(3)
e. None of the above
Ans: a
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
115. How to load an excel file into QTP?
a. Datatable.AddSheet("dTC")
b. Datatable.AddSheet(DataTableSheetName)
Datatable.ImportSheet path, sheetname, DataTableSheetName
c. Datatable.ImportSheet path, sheetname, DataTableSheetName
d. None of the above
Ans: b
116. What is Regular expression?
a. Used in pattern matching of Strings
b. Used in pattern matching of Numeric value
c. Regular expressions provide tools for developing complex pattern matching
d. None of the above
Ans: c
117. How to check "L" exists in 'ITeLearn' word?
a. InStr("ITeLearn","L")
b. Mid("ITeLearn",1)
c. InStrRev("ITeLearn","L")
d. Left("ITeLearn",3)
e. None of the above
Ans: a
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
118. IT__E_LEARN how to get only 'ITELEARN' using any function
a. InStr("IT__E_LEARN","")
b. Replace ("IT__E_LEARN","_","")
c. Mid ("IT__E_LEARN","_","")
d. Right ("IT__E_LEARN","_","")
Ans: b
119. How to add 15 days in a date?
a. Date ("m", 15, Date)
b. Date ("d", 15, Date)
c. Date Add ("m", 15, Date)
d. Date Add ("d", 15, Date)
Ans: d
120. How to get any particular word from a string?
a. Using IntStr function
b. Using Mid function
c. Using Left function
d. Using Right function
Ans: b
121. What is the use of Trim Function?
a. Removes spaces from left of string
b. Removes spaces from right of string
c. Removes spaces from left and right of string
d. None of the above
Ans: c
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
122. How to Reverse the sting "Welcome to Itelearn"?
a. StrReverse("Welcome to itelearn")
b. InStrRev("Welcome to itelearn")
c. InStr("Welcome to itelearn")
d. Reverse("Welcome to itelearn")
Ans: a
123. What is Split function?
a. Splits string and stores in a variable
b. Reverse the string and stores in a array
c. Splits string and stores in two dimensional array
d. The Split function returns a zero-based, one-dimensional array that contains a specified
number of substrings
Ans: d
Chapter: 4
124. Does QTP support Data Driven Framework?
a. No
b. Only supports Modular framework
c. Yes
d. Only supports Keyword driven framework
e. None of the above
Ans: c
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
125. In___ approach tests can be executed multiple sets of test data
a. Data Driven Framework
b. Modular Framework
c. Keyword Driven Framework
d. Hybrid Framework
Ans: a
126. What is the basic approach of Data Driven Framework?
a. Code and Data as a single unit
b. Code and Data as separate units
c. None of the above
Ans: b
127. Which statement is correct to create excel automation object?
a. Set objExl = CreateObject("Application.Excel")
b. Set objExl = Create("Excel.Application")
c. objExl = CreateObject("Excel.Application")
d. Set objExl = CreateObject("Excel.Application")
Ans: d
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
128. Find out the correct option to open a excel file for read or write.
a. Set objExl = CreateObject("Excel.Application")
objExl.Workbooks.Open ExcelPath
b. Set objExl = CreateObject("Excel.Application")
objExl.Open ExcelPath
c. Set objExl = CreateObject("Excel.Application")
objExl.Application.Open ExcelPath
d. objExl.Workbooks.Open ExcelPath
Ans: a
129. vCellData = mySheet.Cells(Row,Col)
This statement will give provided cell data
a. FALSE
b. TRUE
c. Syntax not correct
d. None of the above
Ans: b
130. mySheet.Cells(Row, Col) = 12
This statement used to write in excel cell
a. Syntax Error
b. FALSE
c. TRUE
d. All of the above
Ans: c
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
131. In Data Driven Framework, data can be only accessed from excel.
a. TRUE
b. FALSE
Ans: b
132. QTP Data table cannot be used in Data Driven Framework.
a. FALSE
b. TRUE
Ans: a
133. Data Driven Framework used for only one set of Test Data
a. TRUE
b. FALSE
Ans: b
134. Which statement correctly used to open any excel sheet? If objExcel object is already
created
a. Set mySheet = objExcel.ActiveWorkBook.WorkSheets(xlSheet)
b. mySheet = objExcel.ActiveWorkBook.WorkSheets(xlSheet)
c. Set mySheet = objExcel.WorkSheets(xlSheet)
d. Set mySheet=objExcel.WorkSheets("Sheet1")
e. Both (a) and (d)
Ans: e
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
135. How to close active excel sheet using vbscript statement? If objExcel object is already
created
a. objExcel.close
b. activeworkbook.close
c. objExcel.activeworkbook.close
d. objExcel.activeworkbook.quit
e. All of the Above
Ans: c
136. ___Statement is used to close excel automation object. If objExcel object is already
created
a. objExcel.Application.Quit
b. objExcel.Close
c. Application.Quit
d. Application.Close
e. None of the above
Ans: a
137. ___Statement is used to save modified excel. If objExcel object is already created
a. objExcel.save
b. objExcel.activeworkbook.save
c. activeworkbook.save
d. Both (1) and (3)
e. All of the Above
Ans: b
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
138. Following statement is ___."In Data Driven Framework you can not use Descriptive
programming"
a. TRUE
b. FALSE
c. Only supports Object Repository
d. Data Driven Framework does not Object Repository
e. None of the above
Ans: b
139. Function libraries concept cannot be implemented in Data Driven Framework. Is it
right?
a. Yes
b. May be
c. No
d. Both (a) and (b)
e. All of the Above
Ans: c
140. In Data Driven Framework, can you access data from database?
a. Yes
b. No
c. May be
d. all of the Above
Ans: a
141. Statement is _____"Data Driven Framework does not support Actions"
a. TRUE
b. FALSE
c. May be
d. None of the above
Ans: b
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
142. Do While xlRead(xlPath, xlSheet, i,1) <> ""
statements
Loop
What this loop will do? xlRead() functions is already defined
a. Infinite loop
b. will not execute
c. Syntax error
d. Will read first columns cells for different rows and execute till loop finds a blank cell in
excel file
e. None of the above
Ans: d
143.Does Data Driven Framework supports parallel execution of scripts?
a. Yes
b. No
c. May be
d. All of the above
Ans: b
Chapter: 5
144. ___Statement is used for method overriding in QTP
a. RegisterUserFunc
b. Method Override
c. Class Override
d. None of the above
Ans: a
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
145. RegisterUserFunc statement can also be used for Method reuse
a. FALSE
b. TRUE
c. None of the above
Ans: b
146. IsArray is used ____?
a. To declare array
b. To get length of an array
c. To declare dynamic array
d. A function indicates whether a specific variable is array or not
e. None of the above
Ans: d
147. How to join array of substrings?
a. By + operator
b. By & operator
c. Join (Arr)
d. All of the above
Ans: c
148. In Array, LBound for any dimension is ___
a. 1
b. 0
c. 2
d. 3
e. None of the above
Ans: b
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
149. ReDim Preserve Arr()
In this statement what is the significance of Preserve keyword?
a. Preserves the data in an existing array when you change the size of the last dimension
b. Removes the data from exiting array and stores new data in array
c. Used to Resize the array
d. All of the above
Ans: a
150. ____ statement is used to size or resize a dynamic array that has already been formally
declared using a Private, Public, or Dim statement with empty parentheses
a. Dim
b. Preserve
c. ReDim Preserve
d. ReDim
e. None of the above
Ans: d
151. ____ Reinitializes the elements of fixed-size arrays and deallocates dynamic-array
storage space
a. Dim
b. Erase
c. ReDim Preserve
d. ReDim
e. All of the above
Ans: b
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
151. How to disassociate an object variable from any actual object
a. MyObject = Nothing
b. Set = Nothing
c. Set MyObject = Nothing
d. Set MyObject = Quit
e. None of the above
Ans: c
152. ___ this is used to size or resize a dynamic array
a. Preserve
b. ReDim
c. Dim
d. IsArray
e. None of the above
Ans: b
Chapter: 6
153. Can Descriptive programming be used with Smart Identification?
a. Yes
b. No
Ans: b
154. Which option is correct to create a description object?
a. Set myObj = Description.Create()
b. Set = Description.Create()
c. myObj = Description.Create()
d. Set myObj = Description
e. All of the above
Ans: a
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
155. Is it possible to use descriptive programming inside a Checkpoint?
a. Yes
b. May be
c. No
Ans: c
156. Which option will provide you number of Edit boxes on a page?
a. Set Desc = Description.Create()
Desc("micclass").Value = "WebEdit"
Set Edits = Browser("Google Sets").Page("Google Sets").ChildObjects()
MsgBox "Number of Edits: " & Edits.Count
b. Set Desc = Description.Create()
Desc("micclass").Value = "Link"
Set Edits = Browser("Google Sets").Page("Google Sets").ChildObjects(Desc)
MsgBox "Number of Edits: " & Edits.Count
c. Set Desc = Description.Create()
Desc("index").Value = 0
Set Edits = Browser("Google Sets").Page("Google Sets").ChildObjects(Desc)
MsgBox "Number of Edits: " & Edits.Count
d. Set Desc = Description.Create()
Desc("micclass").Value = "WebEdit"
Set Edits = Browser("Google Sets").Page("Google Sets").ChildObjects(Desc)
MsgBox "Number of Edits: " & Edits.Count
Ans: d
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
157. A statement can be combination of both Object repository and Descriptive
programming approach
a. TRUE
b. FALSE
c. May be
Ans: a
158. ____ stores the properties and values of a particular object in an instance of that
object
a. Object
b. Description Object
c.Object Repository
d. None of the above
Ans: b
159. You cannot use multiple properties to identify an object in DP
a. TRUE
b. FALSE
Ans: b
160. Which approach is followed in this statement
Browser("myBro”).page(“myPage”).webbutton(“Enter”).click
a. Descriptive Programming
b. Object Repository
c. Combination of DP and OR
d. All of the above
Ans: b
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
161. Which approach is followed in this statement
Browser (“name:=myBro”).page(“title:=myPage”).webbutton(“name:=Enter”,”type:=
Submit”).click
a. Descriptive Programming
b. Object Repository
c. Combination of DP and OR
d. All of the above
Ans: a
162. Which approach is followed in this statement
Browser ("myBro").page(“title:=myPage”).webbutton("name:=Login").click
a. Descriptive Programming
b. Object Repository
c. Combination of OR and DP
d. None of the above
Ans: c
163. How to enable Smart Identification?
a. File > Settings
b. Tools > Options
c. Resources > Object Repository Manager
d. Tools > Object Identification > environment > Select object class and on right side you
can see "Enable Smart Identification" checkbox selected and few properties under
mandatory properties such as name,title etc.
Ans: d
164. Smart Identification mechanism uses ____ to identify the objects
a. Only Base filter properties
b. Only Optional filter properties
c. Depends upon situation qtp can use either Base filter or Optional filter properties or
combination of both
d. All of the above
Ans: c
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
165. If Smart Identification is used, step is assigned ___ status in test result when no
objects match the learned description.
a. Passed
b. Warning
c. Failed
d. None of the above
Ans: b
166. Enabling Smart Identification always gives correct results
a. TRUE
b. FALSE
Ans: b
167. Can you use regular expressions in Smart Identification?
a. No
b. Yes
c. May be
Ans: a
168. What is Quickest Automation Object Model?
a. It's a way to write scripts so as to automate your applications
b. It's a way to develop frameworks
c. Automation Object Model can not be used in QTP
d. It's a way to write scripts so as to automate your QuickTest operations
e. None of the above
Ans: d
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
169. How to instantiate QTP?
a. Set qtApp = CreateObject()
b. Set qtApp = CreateObject("QuickTest.Application")
c. qtApp = CreateObject()
d. Set = CreateObject("QuickTest")
Ans: b
170: Set qtApp = CreateObject("QuickTest.Application")
Will this statement launch QTP?
a. Yes
b. No
Ans: b
171. How to launch QTP using AOM?
a. Set qtApp = CreateObject("QuickTest.Application")
b. qtp.launch
c. Set qtApp = CreateObject("QuickTest.Application")
qtApp.launch
d. None of the above
Ans: c
172. How to make QTP visible?
a. qtApp.visible = True
b. Set qtApp = CreateObject("QuickTest.Application")
qtApp.launch
c. qtApp.visible
d. All of the above
Ans: a
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
173. How to generate an AOM script with the current QTP settings using QTP?
a. File > Settings > Generate script
b. Tools > Options
c. Tools > Object Identification
d. All of the above
Ans: d
Chapter: 7
174. How do we deal with a dynamic object/continuously changing object at the runtime?
a. By Framework
b. By Descriptive programming and Ordinal identifier
c. By Shared Object Repository
d. None of the above
Ans: b
175. What is the FireEvent method?
a. The FireEvent method is designed to trigger events in an application. e.g onmouseover
b. The FireEvent method is designed to handle unwanted errors at run time
c. The FireEvent method is designed to trigger application functionalities
d. None of the above
Ans: a
176. Can you use Regular expression to handle Dynamic Objects?
a. Yes
b. No
Ans: a
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
177. ".*" Regular expression can be used to ___.
a. Match any single character
b. Match zero or more occurrences of the preceding expressio
c. Match any character zero or more times
d. Match one or more occurrences of the preceding expression
Ans: b
178. What are the Ordinal Identifiers?
a. An ordinal identifier assigns a numerical value to a test object
b. indicates its order or location relative to other objects with an otherwise identical
description
c. This ordered value provides a backup mechanism that enables QuickTest to create a
unique description to recognize an object when the defined properties are not sufficient to
do so
d. All of the above
Ans: d
179. How many types of Ordinal Identifiers are available in QTP?
a. Location
b. Index
c. Creation Time
d. All of the above
Ans: d
180. In test execution, how to close latest browser opened using QTP?
a. Browser("title:=.*").close
b. Browser("index:=1").close
c. Browser("creationtime:=1").close
d. None of the above
Ans: c
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
181. Regular expressions can be used in Shared Object Repository in QTP to handle
Dynamic objects.
a. TRUE
b. FALSE
Ans: a
182. Regular expression [0-9] tells the processor to match any digit in the range of ____
a. Match any digit
b. Match any digit between 0 to 9
c. Match only 0 and 9
d. All of the above
Ans: b
183. How to create regular expression object in vbscript?
a. Set myRegExp = CreateObject("Regexp.Application")
b. Set myRegExp = CreateObject("WSShell.Regexp")
c. Set myRegExp = New RegExp
d. Set myRegExp = CreateObject("Regexp")
Ans: c
184. Regular expression ___ matches the preceding character zero or more times
a. *
b. . (Dot)
c. 
d. .*
Ans: a
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
185. How to get Tool tip of any link in QTP?
a. Can be obtained using only
Window("nativeclass:=tooltips_class32").GetROProperty("text")
b. By using FireEvent("onmouseover") to simulate mouse placing over the link and then
Window("nativeclass:=tooltips_class32").GetROProperty("text")
c. Browser("Yahoo!").Page("Yahoo!").WebElement("text:=My Yahoo!").FireEvent
"onmouseover"
ToolTip = Window("nativeclass:=tooltips_class32").GetROProperty("text")
d. Both 2 and 3
Ans: d
Chapter: 8
186. What is error handling in QTP?
a. If you can predict that a certain event may happen at a specific point in your test or
component, it is recommended to handle that event directly within your test or component
by adding steps
b. Using Recovery Scenario
c. Using On Error Resume Next
d. All of the above
Ans: d
187. If there is error in the code _______ignores it and continue with next line of code.
a. Err.Number
b. Err.Description
c. On Error Resume Next
d. On Error Go to 0
Ans: c
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
188. ______statement disables error handling. If it is enabled using On Error resume Next
a. On Error Go to 0
b. On Error
c. Err.Number
d. Err.Description
Ans: a
189. Err.Number provides ____
a. Description of Error
b. Error number
c. Disables error handling
d. None of the above
Ans: b
190. Err.Description provides ____
a. Error number
b. Disables error handling
c. Description of Error
d. All of the above
Ans: c
191. When to create Recovery Scenario?
a. While executing scripts we may get some Unexpected errors.To recover the test and
continue running script from these unexpected errors we use Recovery Scenarios
b. To handle known errors or expected errors in the test
c. To resume test if any error occurs while executing test
d. All of the above
Ans: a
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
192. In which event you can use Recovery Scenario?
a. Application Crash
b. Pop up window
c. Test Run error
d. Object State
e. All of the above
Ans: e
193. How to open Recovery Scenario manager?
a. File > Settings
b. Tools > Options
c. Resources > Recovery Scenario Manager
d. Automation > Record & Run Settings
Ans: c
194. A Recovery Scenario consists___
a. Trigger Event
b. Recovery Operations
c. Post Recovery Test run option
d. All of the above
Ans: d
195. A function can be called through a Recovery Scenario
a. TRUE
b. FALSE
Ans: a
196. Exist Property with conditional statement can be used to handle errors
a. FALSE
b. TRUE
Ans: b
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
197. Environment variables are like ____
a. Local variables
b. Global variables
c. Can be both
d. None of the above
Ans: b
198. What Types of environment variables available in QTP?
a. Built in
b. User defined internal
c. User defined external
d. All of the above
Ans: d
199. _____Variables that represent information about the test on which the test is run, such
as Test path and Operating system. These variables are accessible from all tests, and are
designated as read-only
a. User defined internal
b. User defined external
c. Built in
d. None of the above
Ans: c
200. ____ variables that we define within the test. The variables are saved with the test and
are accessible only within the test.
a. User defined internal
b. User defined external
c. Built in
d. None of the above
Ans: a
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
201. _____ variables that we predefine in the active external environment variables
file.These can be created using a list of variable-value pairs in an external file in .xml format
a. User defined internal
b. User defined external
c. Built in
d. None of the above
Ans: b
202. Environment.Value(“name”)= “Itelearn”. What is the purpose of this statement in QTP?
a. Calling a user defined internal environment variable
b. Calling a user defined external environment variable
c. Defining an internal environment variable
d. Defind a external environment variable
Ans: c
203. How to create user defined internal environment variable in QTP?
a. File --> settings --> Environment --> select variable type as user defined --> click add icon
(+)
b. File --> settings --> Environment --> select variable type as user defined --> Browse XML
c. Tools --> options --> Environment --> select variable type as user defined --> click add
icon (+)
d. Resorces --> settings --> Environment --> select variable type as user defined --> click
add icon (+)
Ans: a
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
Chapter: 9 & 10
204. What is Keyword driven framework?
a. Where QTP keywords are used to call functions
b. Where pre defined keywords are used to describe actions
c. In this framework multiple data sets can be used to test
d. All of the above
Ans: b
205. Which file is mostly used to define keywords for Keyword Driven Framework?
a. In Text file
b. In Excel file
c. In CSV file
d. All of the above
Ans: b
206. Can manual tester develop tests in Keyword Driven Framework?
a. Yes
b. No
c. May be
d. None of the above
Ans: a
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
207. Can you define different function libraries in Keyword Driven Framework?
a. No
b. Yes
c. May be
d. None of the above
Ans: b
208. Each keyword related to a function defined in function library. Is this statement True?
a. May be
b. FALSE
c. TRUE
d. None of the above
Ans: c
209. While Designing Keyword Driven Framework we can map keywords at ___
a. Operation level
b. Functional level
c. Both Operation and functional level
d. None of the above
Ans: c
210. Keyword Driven Framework does not support descriptive programming.
a. TRUE
b. FALSE
Ans: b
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
211. Does Keyword Driven Framework supports shared object repository?
a. TRUE
b. FALSE
Ans: a
212. In Keyword Driven Framework we mostly use ____ Repository
a. Local
b. Shared
c. None of the above
Ans: b
213. What are the common components of Keyword driven framework?
a. Excel Sheet to Store the Keywords
b. Function Library
c. Object Repository
d. Test Scripts
e. All of the above
Ans: e
214. What is Driver script in framework?
a. Script is used to initialize and read the control files
b. Consists details of all the Test scenarios to be automated.
c. Driver Script reads the Test Case files. Checks the keywords and calls the appropriate
utility script functions based on specific keyword
d. None of the above
Ans: c
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
215. What are the properties you would use for identifying a browser and page when using
descriptive programming?
a) Name
b) Title
c) MicClass
d) CreationTime
e) All of the above
Ans: e
216. There are two browsers opened on your screen. How to close first browser using
Descriptive programming?
a. Browser("title:=.*").Close
b. Browser("Name:=.*").Close
c. Browser("CreationTime:=0").Close
d. None of the above
Ans: c
Chapter: 11
217. ____ is the combination of both keyboard driven and data driven
frameworks
a. Linear Framework
b. Hybrid Framework
c. Modular Framework
d. Keyword Driven Framework
Ans: b
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
218. In Which case we can design Hybrid Framework
a. Rich Application functionality
b. Data sensitive testing
c. Regression testing
d. All of the above
Ans: d
219. What are the advantages of Hybrid framework?
a. Flexible
b. Increases accuracy
c. Highest ROI
d. All of the above
Ans: d
220. Hybrid framework does not support Descriptive programming.
a. TRUE
b. FALSE
Ans: b
221. Different function libraries can be defined in .txt or .vbs files and libraries can be
associated to test.
a. TRUE
b. FALSE
Ans: a
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
222. Which method you can use to associate function library?
a. File > Settings > Resources > Associate Function Library
b. Automation Object Model (AOM)
c. ExecuteFile Method
d. LoadFunctionLibrary Method
e. All of the above
Ans: d
223. How to associate function library at run time?
a. objQTP.Open "C:AutomationSampleTest", False, False
Set objLib = objQTP.Test.Settings.Resources
If objLib.Find("C:SampleFunctionLibrary.vbs") = -1 Then
objLib.Add "C:SampleFunctionLibrary.vbs", 1
End
b. objQTP.Open "C:AutomationSampleTest", False, False
objQTP.Test.Settings.Resources.Libraries
If objLib.Find("C:SampleFunctionLibrary.vbs") = -1 Then
objLib.Add "C:SampleFunctionLibrary.vbs", 1
End
c. objQTP.Open "C:AutomationSampleTest", False, False
Set objLib = objQTP.Test.Settings.Resources.Libraries
If objLib.Find("C:SampleFunctionLibrary.vbs") = -1 Then
objLib.Add "C:SampleFunctionLibrary.vbs", 1
End
d. None of the above
Ans: c
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
224. In Hybrid framework, data can accessed through database, excel file, xml etc.
a. TRUE
b. FALSE
Ans: a
225. Hybrid framework can be implemented for any application.
a. TRUE
b. FALSE
Ans: a
226. What are the frameworks available other than DDF, KDF and Hybrid?
a. Linear Framework
b. Modular Framework
c. Structured Framework
d. All of the above
Ans: d
Chapter: 12 Topic: Database Testing
227. What is Database Testing?
a. Verifying Data Integrity
b. Verifying Data Consistency
c. Data Comparisons
d. Data Back up
e. All of the above
Ans: e
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
228. What is Data comparison?
a. Comparing front end data only
b. Comparing back end data only
c. Comparing front end data with back end or Database table with excel sheet etc
d. All of the above
Ans: c
229. How to test a SQL Query in QTP? Without using database checkpoints?
a.) Pass the Query as a parameter
b.) 1)Connect to the database
2)Execute the query
3)Disconnect the connection
c. Write a function to execute Query without database connection
d. QTP cannot execute SQL Queries
e. None of the above
Ans: b
230. How to open database connection?
a. Set oConnection = CreateObject("ADODB.Connection")
oConnection.Open ConnectionString
b. Set oConnection = CreateObject("ADODB.Connection")
c. CreateObject("ADODB.Connection")
d. ConnectionString ="Driver = {SQL Server};Data Source = <>; Server=<>; Database=<>;
Trusted_Connection=yes"
e. None of the above
Ans: a
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
231. What is Recordset in terms of Database?
a. Recordset also works as a View in Database
b. Recordset is a virtual table which stores data
c. It is used to open database connection
d. The ADO Recordset object is used to hold a set of records from a database table. A
Recordset object consist of records and columns
Ans: d
232. How to create Recordset object in vbscript?
a. Set oConnection = CreateObject("ADODB.Connection")
b. Set oRecordSet = CreateObject("ADODB.Recordset")
c. ConnectionString ="Driver = {SQL Server};Data Source = <>; Server=<>; Database=<>;
Trusted_Connection=yes"
d. None of the above
Ans: b
233. How to create an ADO SQL recordset?
a. set rs=CreateObject("ADODB.recordset")
rs.Open "Select * from Customers", oConnection
b. Set oRecordSet = CreateObject("ADODB.Recordset")
c. set rs=CreateObject("ADODB.recordset")
rs.Open "Select * from Customers"
d. All of the above
Ans: a
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
Chapter: 12 Topic: DotNet Factory
234. What is DotNetFactory in QTP?
a. DOTNetFactory utility object is something which can be used to work with .Net
applications only
b. DotNetFactory can be used with web applications only
c. Enables QTP scripting to directly access methods and properties of a .NET object by
creating an instance of this object
d. DotNetFactory can be used with window applications only
Ans: c
235. DotNetFactory add-in is required in QTP to use its features. Is this statement correct?
a. TRUE
b. FALSE
Ans: b
236. How to create object instance of DotNetFactory?
a. Set oDotNet = CreateObject("DotNetFactory.Net")
b. Set oDotNet = DotNetFactory.CreateInstance (TypeName)
Type Name: full name of the object
c. Set oDotNet = CreateObject("DotNetFactory.Application")
d. All of the above
Ans: b
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
237. How to create object instance of message box?
a. msgbox "<>"
b. MyMsgBox.Show "!! Hello World !!", "My Custom Message box"
c. Set MyMsgBox = DotNetFactory.CreateInstance("System.Windows.Forms.MessageBox",
"System.Windows.Forms")
d. All of the above
Ans: c
238. ____ statement is used to cretae custom user form.
a. Set MyForm = DotNetFactory.CreateInstance("System.Windows.Forms.Form",
System.Windows.Forms)
b. Set MyForm = DotNetFactory.CreateInstance("System.Windows.Forms.MessageBox",
"System.Windows.Forms")
c. Set MyForm = CreateObject("DotNetFactory.Windows.Form")
d. None of the above
Ans: a
Chapter: 12 Topic: MS Word
239. How to create MS Word object in QTP?
a. Set oWord = CreateObject("MSWord.Application")
b. Set oWord = CreateObject("MS.Application")
c. Set oWord = CreateObject("Application.Word")
d. Set oWord = CreateObject("Word.Application")
Ans: d
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
240. ___ statement is used to make MS Word visible. If Word object is already created.
a. oWord.Visible
b. oWord.Visible = True
c. oWord.Visible = False
d. None of the above
Ans: b
241. How to add new document in the opened MS Word? If Word object is already created.
a. oWord.Documents.Add
b. oWord.Add
c. oWord.New
d. All of the above
Ans: a
Chapter: 12 Topic: FSO
242. What is FSO?
a. An object to create folders only
b. An object to create files only
c. File System Object is an object to handle text files only
d. Filesystemobject is an object model which is used to handle the drives, folders, and files
of a system
Ans: d
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
243. How to create a file?
a. First create a FSO object using CreateObject and then create a text file using
CreateTextFile
b. File can be created directly without creating FSO object
c. FSO object can not be used to create files
d. None of the above
Ans: a
244. ____ statement is used to create FSO object.
a. Set fso = CreateObject(“FileSystemObject”)
b. Set fso = CreateObject(“Scripting.FileSystemObject”)
c. Set fso = CreateObject(“FileSystemObject.Scripting”)
d. Set fso = CreateObject(“Scripting.FSO”)
Ans: b
245. ____ statement is used to create text file. Assume FSO object is already created.
a. Set fso = CreateObject(“Scripting.FileSystemObject”)
b. Set file = CreateTextFile(file_location, True)
c. Set file = fso.CreateTextFile(file_location, True)
d. Set file = CreateObject(file_location, True)
Ans: c
246. How to open a file?
a. Set file= fso.OpenTextFile("C:file_location", ForReading, True)
b. Set file= fso.OpenTextFile("C:file_location", ForAppending, True)
c. Set file= fso.OpenTextFile("C:file_location", ForWriting, True)
d. All of the above
Ans: d
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
247. How to read content from a file?
a. data = file.ReadLine()
b. data = fso.ReadLine()
c. data = fso.OpenTextFile("C:file_location", ForReading, True)
d. None of the above
Ans: a
248. How to write content to a file?
a. Set file= fso.OpenTextFile("C:file_location", ForReading, True)
file.Write("Welcome to IteLearn.com")
b. fso.Write("Welcome to IteLearn")
c. Set file= fso.OpenTextFile("C:file_location", ForWriting, True)
file.Write("Welcome to IteLearn.com")
d. All of the above
Ans: c
249. How to delete content?
a. fso.DeleteFile
b. fso.DeleteFile(file_location)
c. file.DeleteFile(file_location)
d. None of the above
Ans: b
Chapter: 12 Topic: Virtual Objects
250. Virtual objects enable you to record and run tests on objects that are normally
recognised by QTP.
a. TRUE
b. FALSE
Ans: b
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
251. In the test results, the virtual object is displayed as though it is a standard class
object.
a. TRUE
b. FALSE
Ans: a
252. QTP does not support virtual objects for _____ recording.
a. Analog
b. low level
c. normal
d. Both 1 and 2
Ans: d
253. You can use the object spy to view virtual objects properties.
a. TRUE
b. FALSE
Ans: b
254. You cannot insert any type of checkpoint on a virtual object
a. TRUE
b. FALSE
Ans: a
255. The ____ contains all the virtual object collections defined.
a. Virtual Object Manager
b. Virtual Manager
c. Virtual Object Wizard
d. None of the above
Ans: a
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
256. Extension of virtual object collection files
a. .vcf
b. .vot
c. .vct
d. .vcd
Ans: b
257. You can remove virtual objects from your test by ___ these objects.
a. disabling recognition of
b. deleting
c. deleting virtual object collection files of
d. All of the above
e. Both 1 and 2
Ans: e
258. QTP identifies a virtual object according to its ____.
a. Properties
b. Boundaries
c. Object Spy
d. Edges
Ans: b
Chapter: 13 Topic: Shell Scripting
259. How to display a message with some wait time?
a. Set wshShell = CreateObject("Wscript.Shell")
wshShell.popup "Karthik", 5, "IteLearn"
b. Set wshShell = CreateObject("Wscript.Shell")
wshShell.msgbox "Karthik", 5, "IteLearn"
c. msgbox "IteLearn"
d. None of the above
Ans: a
QTP Interview Questions and Answers
Website: http://www.ITeLearn.com
Email: learn@itelearn.com
Contact: +1-314-827-5272, +91-837-4323-742(India)
260. How to send keyboard inputs?
a. Set oShell = CreateObject("WScript.Network")
oShell.SendKeys "IteLearn"
b. Set oShell = CreateObject("WScript.Shell")
oShell.SendKeys "IteLearn"
c. WScript.SendKeys "IteLearn"
d. All of the above
Ans: b
261. How to display current user name of the system?
a. Set wshShell = CreateObject("Wscript.Shell")
User_Name = wshShell.username
b. Set wshShell = CreateObject("Wscript.Network")
User_Name = wshShell.user
c. Set wshShell = CreateObject("Wscript.Network")
User_Name = wshShell.username
d. None of the above
Ans: c

More Related Content

PDF
Qtp Interview Questions
DOCX
Qtp questions
DOCX
QTP Interview Questions and answers
PPT
Qtp not just for gui anymore
DOCX
Qtp 11 notes
DOC
Qtp certification questions and answers
DOCX
Data Base Testing Interview Questions
PPT
Stopping the Rot - Putting Legacy C++ Under Test
Qtp Interview Questions
Qtp questions
QTP Interview Questions and answers
Qtp not just for gui anymore
Qtp 11 notes
Qtp certification questions and answers
Data Base Testing Interview Questions
Stopping the Rot - Putting Legacy C++ Under Test

What's hot (20)

PPTX
Testes? Mas isso não aumenta o tempo de projecto? Não quero...
DOC
Qtp faqs
DOC
Interview questions in qtp
PPT
RPG Program for Unit Testing RPG
PPT
Unit Testing RPG with JUnit
ODT
Testing in-python-and-pytest-framework
PDF
Testing Legacy Rails Apps
PPT
20111018 boost and gtest
PPT
Presentation_C++UnitTest
PPTX
TDD and the Legacy Code Black Hole
PDF
JUnit 5 - Evolution and Innovation - SpringOne Platform 2019
PPTX
Grails 1.1 Testing - Unit, Integration & Functional
PPTX
Interpreter RPG to Java
PPTX
Applying TDD to Legacy Code
PPTX
RelProxy, Easy Class Reload and Scripting with Java
DOC
Qtp interview questions3
DOC
Qtp training in hyderabad
PPTX
[Webinar] Qt Test-Driven Development Using Google Test and Google Mock
 
PDF
PPTX
Quickly Testing Qt Desktop Applications
Testes? Mas isso não aumenta o tempo de projecto? Não quero...
Qtp faqs
Interview questions in qtp
RPG Program for Unit Testing RPG
Unit Testing RPG with JUnit
Testing in-python-and-pytest-framework
Testing Legacy Rails Apps
20111018 boost and gtest
Presentation_C++UnitTest
TDD and the Legacy Code Black Hole
JUnit 5 - Evolution and Innovation - SpringOne Platform 2019
Grails 1.1 Testing - Unit, Integration & Functional
Interpreter RPG to Java
Applying TDD to Legacy Code
RelProxy, Easy Class Reload and Scripting with Java
Qtp interview questions3
Qtp training in hyderabad
[Webinar] Qt Test-Driven Development Using Google Test and Google Mock
 
Quickly Testing Qt Desktop Applications
Ad

Viewers also liked (11)

PDF
Interview questions and answers for quality assurance
PDF
132 qa interview questions and answers pdf
PDF
Automation Testing using Selenium
DOC
Manual Testing
DOC
Manual testing interview question by INFOTECH
DOCX
OSMAN MOHAMED FARGHALI
PDF
AMR KHALIL C.V.(1)
PPTX
Actions in QTP
PDF
Introduction to Automation Testing and Selenium overiew
PPTX
Interview question tips
PDF
Html interview-questions-and-answers
Interview questions and answers for quality assurance
132 qa interview questions and answers pdf
Automation Testing using Selenium
Manual Testing
Manual testing interview question by INFOTECH
OSMAN MOHAMED FARGHALI
AMR KHALIL C.V.(1)
Actions in QTP
Introduction to Automation Testing and Selenium overiew
Interview question tips
Html interview-questions-and-answers
Ad

Similar to Qtp interview questions and answers (20)

PDF
Selenium webdriver interview questions and answers
PPTX
Part - 2 Cpp programming Solved MCQ
PDF
Java Software Solutions 8th Edition Lewis Test Bank
PDF
Java Software Solutions 8th Edition Lewis Test Bank
PDF
Java Software Solutions 8th Edition Lewis Test Bank
DOC
Java questions1
PDF
Java Software Solutions 8th Edition Lewis Test Bank
PDF
Java Software Solutions 8th Edition Lewis Test Bank
PDF
How to Prepare for the Python PCAP Certification Tips & Resources.pdf
PDF
Java Software Solutions 8th Edition Lewis Test Bank
PDF
Java Software Solutions 8th Edition Lewis Test Bank
PDF
Java Software Solutions Foundations of Program Design 7th Edition Lewis Test ...
ODP
Let's talk about Certifications
PDF
Java Software Solutions Foundations of Program Design 7th Edition Lewis Test ...
PDF
Java Software Solutions 8th Edition Lewis Test Bank
PDF
PyCon JP 2024 Streamlining Testing in a Large Python Codebase .pdf
PPTX
UGC-NET, GATE and all IT Companies Interview C++ Solved Questions PART - 2
PDF
Checkpoint.Premium.156-315.80.by.VCEplus.471q.pdf
PDF
EuroPython 2024 - Streamlining Testing in a Large Python Codebase
PDF
Developer Android Tools
Selenium webdriver interview questions and answers
Part - 2 Cpp programming Solved MCQ
Java Software Solutions 8th Edition Lewis Test Bank
Java Software Solutions 8th Edition Lewis Test Bank
Java Software Solutions 8th Edition Lewis Test Bank
Java questions1
Java Software Solutions 8th Edition Lewis Test Bank
Java Software Solutions 8th Edition Lewis Test Bank
How to Prepare for the Python PCAP Certification Tips & Resources.pdf
Java Software Solutions 8th Edition Lewis Test Bank
Java Software Solutions 8th Edition Lewis Test Bank
Java Software Solutions Foundations of Program Design 7th Edition Lewis Test ...
Let's talk about Certifications
Java Software Solutions Foundations of Program Design 7th Edition Lewis Test ...
Java Software Solutions 8th Edition Lewis Test Bank
PyCon JP 2024 Streamlining Testing in a Large Python Codebase .pdf
UGC-NET, GATE and all IT Companies Interview C++ Solved Questions PART - 2
Checkpoint.Premium.156-315.80.by.VCEplus.471q.pdf
EuroPython 2024 - Streamlining Testing in a Large Python Codebase
Developer Android Tools

Recently uploaded (20)

PDF
Sales and Distribution Managemnjnfijient.pdf
PPTX
1751884730-Visual Basic -Unitj CS B.pptx
PPTX
E-Commerce____Intermediate_Presentation.pptx
PDF
Blue-Modern-Elegant-Presentation (1).pdf
PDF
APNCET2025RESULT Result Result 2025 2025
PPTX
A slide for students with the advantagea
PPTX
Surgical thesis protocol formation ppt.pptx
PDF
Why Today’s Brands Need ORM & SEO Specialists More Than Ever.pdf
PPT
APPROACH TO DEVELOPMENTALlllllllllllllllll
PPTX
Cerebral_Palsy_Detailed_Presentation.pptx
PPTX
AREAS OF SPECIALIZATION AND CAREER OPPORTUNITIES FOR COMMUNICATORS AND JOURNA...
PDF
シュアーイノベーション採用ピッチ資料|Company Introduction & Recruiting Deck
PPTX
Job-opportunities lecture about it skills
PDF
MCQ Practice CBT OL Official Language 1.pptx.pdf
PPTX
Overview Planner of Soft Skills in a single ppt
PPTX
Your Guide to a Winning Interview Aug 2025.
DOCX
mcsp232projectguidelinesjan2023 (1).docx
PDF
L-0018048598visual cloud book for PCa-pdf.pdf
PDF
Understanding the Rhetorical Situation Presentation in Blue Orange Muted Il_2...
PDF
Josh Gao Strength to Strength Book Summary
Sales and Distribution Managemnjnfijient.pdf
1751884730-Visual Basic -Unitj CS B.pptx
E-Commerce____Intermediate_Presentation.pptx
Blue-Modern-Elegant-Presentation (1).pdf
APNCET2025RESULT Result Result 2025 2025
A slide for students with the advantagea
Surgical thesis protocol formation ppt.pptx
Why Today’s Brands Need ORM & SEO Specialists More Than Ever.pdf
APPROACH TO DEVELOPMENTALlllllllllllllllll
Cerebral_Palsy_Detailed_Presentation.pptx
AREAS OF SPECIALIZATION AND CAREER OPPORTUNITIES FOR COMMUNICATORS AND JOURNA...
シュアーイノベーション採用ピッチ資料|Company Introduction & Recruiting Deck
Job-opportunities lecture about it skills
MCQ Practice CBT OL Official Language 1.pptx.pdf
Overview Planner of Soft Skills in a single ppt
Your Guide to a Winning Interview Aug 2025.
mcsp232projectguidelinesjan2023 (1).docx
L-0018048598visual cloud book for PCa-pdf.pdf
Understanding the Rhetorical Situation Presentation in Blue Orange Muted Il_2...
Josh Gao Strength to Strength Book Summary

Qtp interview questions and answers

  • 1. Website: http://www.ITeLearn.com Email : learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) QTP Interview Questions and Answers
  • 2. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 1. What is the output on the print screen when this code gets executed? (Please try without using QTP or a VB Script executor). Dim vString, vInt vInt = "Hello" vString = 25 print vInt + vString a. RunTime Error Hint: Occurs during the running of the script. b. Hello25 c. Cannot add String and Integer using "+" sign d. Syntax Error Hint: Error in writing our code correctly. e. vIntvString Ans: b Chapter: 1 Topic: Video1 1. Which tests is the better candidate for Automation a. Test Cases that is easy to Automate b. Test cases that are repeatedly executed manually which will have a greater Return on Investment (ROI) c. Adhoc Tests d. Exploratory Tests e. All of the above Ans: b
  • 3. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 2. Primary goal of test automation is a. To reduce the testing project's effort b. To reduce the number of tests to be run manually c. Eliminate manual testing d. Faster release cycles e. All of the above Ans: b 3. Framework Analysis and recommendations for improvements are done during the a. Automation Test Strategy phase b. Design phase c. Build phase d. Both 1 and 2 e. Only 3 Ans: a 4. In QTP, the ______________ provides the snap shot / screen shot of the application as it appeared during the recording session. a. Expert View b. Keyword View c. Active Screen d. Record and Run Settings e. Actions Ans: c
  • 4. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 5. What is the Syntax for instructing QTP to wait for 5 seconds between two steps? a. object.Wait(5) b. delay(5) c. timer(5) d. wait(5) e. Sync(5) Ans: d 6. What is the Navigation path for Accessing "Record and Run Settings"? a. File ==> Test ==> Record and Run Settings b. View ==> Record and Run Settings c. Resources => Record and Run Settings d. Tools => Record and Run Settings e. Automation ==> Record and Run Settings Ans: e 7. What are the Recording Modes Available in QTP? a. (1) Web Based (2) Windows Based b. (1) Functional (2) Non Functional c. (1) Context Sensitive/ Normal Recording Mode (2) Analog Recording Mode (3) Low Level Recording d. (1) Keyboard Recording Mode (2) Mouse Recording Mode Ans: c
  • 5. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 8. Which is the Default Recording Mode in QTP? a. Context Sensitive b. Analog Recording Mode c. Low Level Recording d. Keyboard Recording Mode e. None of the above Ans: a 9. Which Recording Mode Records mouse clicks with co-ordinates? a. Analog Recording Mode b. Low Level Recording c. Context Sensitive d. Both 1 and 2 e. All the Above Ans: b 10. Which of the following DOESNOT record Object Information while recording a. Analog Recording Mode b. Low Level Recording c. Context Sensitive d. Both 1 and 2 e. None of the above Ans: a
  • 6. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 11. Which of the following recording modes DOESNOT Allow user to EDIT scripts after Recording? a. Low Level Recording b. Context Sensitive c. Analog Recording Mode d. Both 1 and 3 e. None of the above Ans: c 12. How to make QTP to show the Results of the Test immediately after the Test Script Execution a. File -> settings-> Run b. Tools ==> Options ==> Run c. View ==> Test Results d. Automation ==> Settings ==> Run e. There is no such feature available in QTP to show the results automatically. Ans: b Chapter: 1 Topic: Video2 13. What are the Default set of add-ins installed automatically with Quick Test Pro Installation? a. (1) Active X, VB, .NET b. (2) Active X, Java, Web c. (3) Active X, Java, VB d. (4) Active X, VB, Web e. (5) Active X, .NET, Java, VB, Web Ans: d
  • 7. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 14. How the Test Set in QTP is saved? a. .vbs b. .tsr c. .qfl d. quick test tests e. None of the above Ans: d 15. How to comment a line in VB Scripting? a. A comment should commence with a Single Quote or "REM" b. Statement should start with the keyword c. A single Comma d. It should start with /* and end with */ e. Statement should start with * Ans: a 16. What is the Short cut for commenting and Uncommenting an existing line of Code? a. (1) Ctrl + M for Commenting (2) Shift + Ctrl + M for UnCommenting b. (1) ALT + M for Commenting (2) ALT + Ctrl + M for UnCommenting c. (1) Shift + M for Commenting (2) Alt + Shift + M for UnCommenting d. (1) Shift + Ctrl + M for Commenting (2) Ctrl + M for Uncommenting e. None of the above Ans: a
  • 8. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 17. ________________ is used for executing a single statement if that statement is a function call or action call then it will step onto that function or action a. Step onto b. Step over c. Step into d. step out e. None of the above Ans: c 18. ___________ is used for executing all the remaining statement in that in that function call or action from the position of pointer a. Step onto b. Step over c. Step into d. Step Out Ans: d 19. ____________ is used for executing a single statement if that statement is a function call or action call then it will execute the complete block of statements once present in the function/action a. Step onto b. Step over c. Step into d. Step Out Ans: b
  • 9. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 20. Shortcuts for Step into, Step over and Step out a. (1) Step Into F11 (2) Step Over F10 (3) Step Out SHIFT + F11 b. (1) Step Over F11 (2) Step Into F10 (3) Step Out SHIFT + F11 c. (1) Step Out F11 (2) Step Into F10 (3) Step Over SHIFT + F11 d. (1) Step Into F10 (2) Step Over F11 (3) Step Out SHIFT + F11 Ans:a 21. How a user can insert a Break Point a. By Pressing "F9" after keeping the focus on the statement where the user wants the Break point b. Debug => Insert/Remove Breakpoint c. The breakpoint can be inserted by just clicking on the left margin of the executable statement d. All the Above Ans: d 22. Break Points are saved with the QTP Tests/Function Libraries a. True b. FALSE Ans: b
  • 10. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 23. What is the Short cut to remove all Break points? a. Ctrl + F9 b. Shift + Ctrl+ F9 c. Alt + Ctrl+ F9 d. Shift + F9 e. all of the above Ans: b 24. User will be able to add break points when the window session is in "Break" Mode a. True b. FALSE Ans: b 25. What does a break point do? a. Stops test execution at the specified step, after executing that step b. Stops test execution at the specified step, before executing that step. c. Pauses test execution at the specified step, after executing that step d. Pauses test execution at the specified step, before executing that step. e. all of the above Ans:d
  • 11. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 26. Which method is used to enter a text in a text box/web edit? a. obj.SetText "ABC" b. obj.SetValue "ABC" c. obj.Set "ABC" d. obj.Enter "ABC" Ans: c 27. Which of the following method is used to select a value from a list box a. obj.SelectValue "ABC" b. obj.Select "ABC" c. obj.ListSelect "ABC" d. obj.SelectListValue "ABC" Ans: b 28. Which of the following method is used to perform a click on a object a. Obj.Click b. Obj.Activate c. Obj.Mouseclick d. Obj.PerformClick Ans: a
  • 12. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) Chapter: 1 Topic: Video3 29. How QTP identity objects a. QTP can recognise any object without knowing any description of the object b. QTP uses the learned description to identify objects c. QTP stores the object properties while recording and on playback, uses the learned properties to identify d. Both (2) and (3) e. None of the above Ans: c 30. What is object repository? a. A file where QTP stores Actions b. A file where QTP stores scripts c. A file where QTP stores Run Time objects d. A file where QTP stores Test Objects e. All of the above Ans: d 31. What are the types of object repository? a. Only Local b. Only Shared c. Local and Shared d. There are no Local or Shared object repositories Ans: c
  • 13. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 32. What is child object? a. There is no child object concept b. Object contained within the another object c. Child Objects is a method d. All of the above Ans: b 33. In which hierarchy QTP stores objects in Object Repository a. QTP stores objects form Parent to child hierarchy b. QTP stores only Child objects c. QTP stores only Parent objects d. QTP does not store any object Ans: a 34. QTP can store objects in object repository only on recording a. TRUE b. FALSE c. May be d. None of the above Ans: b 35. What is Active Screen? a. Where the script is generated b. Where object is stored c. It is Keyword view where steps are displayed d. Active screen provides the snap shot or screen shot of the application e. None of the above Ans: d
  • 14. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 36. What is checkpoint in QTP? a. Used to debug script b. Work same as Breakpoint c. Checkpoint is a verification point d. Checkpoint is method e. All of the above Ans: c 37. What is variable in terms of vbscript a. Variables are used to hold values or expressions b. Variables are used to store objects c. Variables are used to store actions d. All of the above Ans: a 38. Types of variables in vbscript a. Variant b. Only Boolean c. Only Integer d. There are different kind of variables like Integer, Boolean, Long, Double etc Ans: a 39. File extension for local and shared object repository a. .mtr and .bdb b. .bdb and .tsr c. Only .bdb d. Only .tsr e. None of the above Ans: b
  • 15. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 40. Can we change logical names of the object in OR a. Cannot be changed b. No c. Yes d. None of the above Ans: c Chapter: 1 Topic: Video4 41. What is Syntax error in script? a. Syntax error is a grammatical error b. A syntax error in programming where the code that is written by a programmer which is incorrect as per the language structure c. Syntax error is logical error in script d. There are no such types of error Ans: b 42. In QTP where you can provide URL and launch your application a. In Settings option b. Tools -> Options c. Automation -> Record and Run Settings d. Both (1) and (2) Ans: c 43. What does SystemUtil.Run do a. It starts test execution b. It invokes the QTP c. It opens browser with mercury website URL d. SystemUtil.Run is an inbuilt QTP command that lets you run a file or an application e. All of the above Ans: d
  • 16. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 44. How you can add objects in OR a. Object can be added using Add Object button in OR b. Object can be added using drag and drop c. Objects cannot be added to OR d. Record some actions on the object; this will automatically add this object to the object repository e. None of the above Ans: a and d 45. What are conditional statements? a. Conditional statements are used to execute same block of code for a specified number of times b. Conditional statements are used to perform different actions for different decisions c. Comments in VbScript knows as conditional statements d. You can control the flow of your script with conditional statements e. Both (b) and (d) Ans: e 46. What is "For Next" loop in vbscript? a. A conditional statement b. A type of variable in VbScript c. Looping statements are used to run the same block of code for a specified number of times d. Both (1) and (2) e. All of the above Ans: c
  • 17. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 47. What is the Syntax of "For Next" loop in vbscript? a. For i to n b. For i = 0 to n c. For i = 0 to n Next d. For i = 0 to n Step 2 Next e. All of the above Ans: c & d Chapter: 1 Topic: Video5 48. What is Dim statement in vbscript? a. To declare only Integer data types b. Declares and allocates storage space for one or more variables c. It is a variable type in vbscript d. It is a conditional statement e. None of the above Ans: b 49. How to declare a variable in vbscript? a. Int i b. String i c. Dim i d. ReDim i e. All of the above Ans: c
  • 18. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 50. You have a variable i, Define it correctly with any value a. Dim i b. i c. Dim i = 10 d. i = 10 e. all of the above Ans: c 51. What is Option Explicit statement in vbscript? a. Used at script level to force explicit declaration of all variables in that script b. Used to declare a variable c. It forces you to declare all of your global variables d. It forces you to call the method e. It forces you to declare all of your static variables Ans: a 52. Find the variable which is defined as a Integer a. Dim a = "abc" b. Dim a = 10 c. DIm a = 10.50 d. TRUE e. All of the above Ans: b
  • 19. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 53. Find the variable which is defined as a String a. Dim a = "abc" b. Dim a = 10 c. DIm a = 10.50 d. FALSE e. All of the above Ans: a 54. Find the variable which is defined as a Float a. Dim a = "abc" b. Dim a = 10 c. DIm a = 10.50 d. TRUE e. All of the above Ans: c 55. What are different types operators available in vbscript? a. Only Arithmetic b. Only Logical c. Only Comparison d. Arithmetic Comparison Logical Ans: d
  • 20. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 56. Concatenate two strings "Welcome to" and "IteLearn.com" a. "Welcome to" + "IteLearn.com" b. "Welcome to" ++ "IteLearn.com" c. "Welcome to" & "IteLearn.com" d. "Welcome to" && "IteLearn.com" e. All of the above Ans: c 57. In which expression Addition operator is used correctly a. 3 + 5 b. 3 ++ 5 c. 3 & 5 d. 3 && 5 e. None of the above Ans: a 58. What is the function of Modulus operator (Mod)? a. Divides two numbers and returns the integer part b. Divides two numbers and returns only the remainder c. Divides two numbers and returns the decimal part d. Divides two numbers and returns the result Ans:b
  • 21. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) Chapter: 1 Topic: Video6 59. Which method will you use to get any property value of an Object at run time? a. By GetROProperty b. By GetTOProperty c. By SetROProperty d. By SetTOProperty e. All of the above Ans: a 60. What is GetROProperty method? a. Method to retrieve the current value of an identification property from a test object in your application b. Method to Set value of an identification property of a run-time object in your application c. Method to retrieve the current value of an identification property from a run-time object in your application d. Method to retrieve the property of an identification property from a run-time in your application Ans: c 61. Where you can use GetTOProperty method? a. Method enables you to retrieve a specific property and value that QTP uses to identify an object. b. Method enables you to set a specific property value of that QTP uses to identify an object. c. Method to retrieve the current value of an identification property from a run-time object in your application d. Both b and c Ans: a
  • 22. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 62. What is use of SetTOProperty method in QTP? a. Method to retrieve the current value of an identification property from a run-time object in your application b. Method to retrieve the property of an identification property from a run-time in your application c. Method enables you to retrieve a specific property and value that QTP uses to identify an object. d. Method enables you to modify a property value that QTP uses to identify an object Ans: d Chapter: 2 Topic: Actions 63. Actions call can be added to a test during ____ in QTP. a. Recording b. Designing c. Editing d. All of the above e. None of the above Ans: b 64. When you create a new test in QTP, it contains ___. a. Multiple Actions b. Single Action c. All of the above d. None of the above Ans: b
  • 23. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 65. Which action you can insert in your current test in QTP? a. Stored in current test b. Stored within an another test c. All of the above d. None of the above Ans: c 66. For every action QTP creates a corresponding action sheet in the Data Table. Is this statement correct? a. No b. Yes c. None of the above Ans: b 67. What you can choose to view after opening the test? a. Test flow (calls to actions) b. View and edit the individual actions stored with your test. c. Both A & B d. None of the above Ans: c 68. For every action called in your test, QuickTest creates a corresponding ........ in the Data Table so that you can enter Data Table parameters that are specific to that action only. a. Action sheet b. Excel sheet c. Both A & B d. None of the above Ans: a
  • 24. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 69. What are the types of Actions in QTP? A. Non-reuse action, Reuse action, External action b. Call to internal action, Call to reusable action, external action c. Non-reusable action, Reusable action, External action d. Call to non-reusable action, reusable action, external action Ans: c 70. By default, new actions are ___ a. Short b. External c. Reusable d. Non-reusable Ans: d 71. You can display or hide the Action toolbar in the Keyword View by choosing ........ a. View > Toolbars > Action b. View > Toolbars > Actions c. View > Toolbar > Action d. Views > Toolbars > Action Ans: a 72. The ...... enables you to view either the entire test flow or you can view the steps for a selected reusable or external action a. Action Flow b. Action file c. Action List d. Action Repository Ans: c
  • 25. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 73. In the ......., the Action List is always visible and the Expert View always displays the script for the selected action a. Keyword View b. Expert View c. Action Flow d. Action View Ans: b 74. If the action is called more than once within the test flow or if the action is called by a reusable action, the Reusable action option is..... a. read-only b. write-only c. both read and write d. read-write-executable Ans: a 75. You cannot expand ...... actions from the test flow view a. reusable b. non-reusable c. both A & B d. None of the above Ans: a 76. You can associate shared object repositories with ...... actions simultaneously, using the Associate Repositories dialog box a. seven b. Two c. Three d. Multiple Ans: d
  • 26. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 77. You can associate ....... object repositories with an action, and the same object repository can be associated with different actions as needed a. Nine b.Twenty one c. as many as you need d. Twelve Ans: c 78. Sometimes you may want to call an action from within an action. This is called....... a. Reusability b. Nesting c. Sharing d. None of the above Ans: b 79. You must use the...... Action option in QuickTest if you want to save an action under another name a. Resave b. Rename c. Reuse d. Split Ans: b 80. You can also press ...... to open the Rename Action dialog box a. Shift + F2 b. Shift + F3 c. Shift + F4 d. Shift + F5 Ans: a
  • 27. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 81. If you want to include one or more statements in every new action in your test, you can create an.... a. reusable action b. split action c. Function d. action template Ans: d 82. Only the file name ...... is recognized as an action template a. ActionTemplate.mst b. Action_Template.mst c. Action-Template.mst d. ActionTemplates.mst Ans: a Chapter: 2 Topic: Checkpoints 83. The ........checks a variety of objects such as buttons, radio buttons, combo boxes, lists, and so forth a. Image checkpoint b. Standard checkpoint c. Bitmap checkpoint d. Accessibility checkpoint Ans: b
  • 28. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 84. You create an image checkpoint by inserting a........ on an image object a. Image checkpoint b. standard checkpoint c. Bitmap checkpoint d. Accessibility checkpoint Ans: b 85. ......... are also supported for some list view objects, such as WinListView and VbListView, as well as other list view objects in external add-in environments a. Table checkpoints b. standard checkpoints c. Accessibility checkpoints d. XML checkpoints Ans: a 86. ........Specifies the time interval (in seconds) during which QuickTest attempts to perform the checkpoint successfully a. Check timeout b. Checkpoint interval timeout c. Checkpoint timeout d. Quicktest timeout Ans: c
  • 29. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 87. You can view the results of the checkpoint in the........ a. Test Results window b. Checkpoint window c. Information Pane d. Checklist window Ans: a 88. By default, the bottom right part of the Test Results window displays information on the selected checkpoint only if it has the status Failed a. TRUE b. FALSE Ans: a 89. You can also use the ......... to check specific property values a. Check Property method b. Check Item Property method c. Item Property method d. Property method Ans: a 90. If you want to retrieve the return value of a checkpoint (a boolean value that indicates whether the checkpoint passed or failed), you must add ......... the checkpoint argument in the statement in the Expert View. a. parentheses around b. Properties with c. Arguments with d. Values along with Ans: a
  • 30. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 91. You can use a formula in a checkpoint to confirm that an object created on-the-fly (dynamically generated) or another variable object in your Web page or application contains the value it should for a given context. a. TRUE b. FALSE Ans: a 92. You cannot modify the settings of existing checkpoints a. TRUE b. FALSE Ans: b Chapter: 3 93. What is Function in vbscript? a. Does not returns a value to the code that calls it b. Returns a value to the code that calls it c. Same as Procedure d. All of the above Ans: b 94. What is Procedure or Subroutine in vbscript? a. Returns a value to the code that calls it b. There is no difference between functions and subroutine c. does not returns a value to the code that calls it d. None of the above Ans: c
  • 31. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 95. You use Exit ____ to exit a Do...While...Loop statement a. Do b. While c. Only Exit d. Loop e. All of the above Ans: a 96. Which statement to force user to explicitly declare variables? a. Explicit b. Option c. No such statement required d. Option Explicit Ans: d 97. A = True, B = True ---> A And B = ? a. TRUE b. FALSE c. None of the above Ans: a 98. Dim Arr() Msgbox Arr(2) What will be the result? a. 1 b. 2 c. 0 d. Error message Ans: d
  • 32. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 99. We use the _____ statement to declare a variable a, ReDim b. Option Explicit c. Dim d. Preserve e. None of the above Ans: c 100. How to get size of any Array? a. LBound (Arr) b. UBound (Arr) c. Len(Arr) d. UBound(Arr) - LBound(Arr) e. All of the above Ans: d 101. Is VbScript is Case sensitive or case insensitive? a. Case Insensitive b. Case sensitive Ans: a 102. By Default in vbscript the argument passed to function or sub routine is _____ a. By Reference b. By Value Ans: a
  • 33. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 103. How to declare an Array in vbscript? a. Arr(4) b. Dim Arr() OR Dim Arr(5) c. ReDim Arr d. Dim Arr e. All of the above Ans: b 104. What is Dictionary Object in vbscript? a. Same as Array b. Stores only Item c. Stores key / item pair d. Stores only Key e. None of the above Ans: c 105. Which function allows to instantiate an object in vbscript? a. Create Object b. Dim c. Set d. Object e. All of the above Ans: a
  • 34. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 106. What is the purpose of On Error Resume Next statement in vbscript? a. Stops execution whenever any error occurred b. Print Error number c. Print Error description d. causes execution to continue with the statement immediately following the statement that caused the run-time error e. None of the above Ans: d 107. How to declare a Class in vbscript? a. Dim Class b. Class name Statements End Class c. CreateObject Class d. Class name Statements End e. None of the above Ans: b
  • 35. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 108. What are the conditional statements in vbscript? A. Only If b. Only Select Case c. If... If...Then...Else If...Then...Else If Select Case d. If... If...Then...Else If...Then...Else If e. None of the above Ans: c 109. What is parameterization in vbscript? a. Checking the same operations with multiple sets of data b. Passing Constant values c. Passing fixed values d. None of the above Ans: a 110. What is the use of ReDim statement in vbscript? a. The ReDim statement is used to size or resize a Static array that has already been formally declared using Dim b. The ReDim statement is used to size or resize a Dynamic array that has already been formally declared using Dim c. Used to declare a variable d. None of the above Ans: b
  • 36. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 111. _____ arrays can be handled by vbscript. a. Only Static b. Only Dynamic c. Both Static and Dynamic d. All Ans: c 112. What is the syntax to find length of any string? a. Len (string) b. Size (string) c. Ubound(string) d. Lbound(string) e. None of the above Ans: a 113. How to convert any string to upper case? a. LCase(string) b. Uppercase(string) c. Lowercase(string) d. UCase(string) Ans: d 114. How to access first element of array? a. Arr(0) b. Arr(1) c. Arr(2) d. Arr(3) e. None of the above Ans: a
  • 37. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 115. How to load an excel file into QTP? a. Datatable.AddSheet("dTC") b. Datatable.AddSheet(DataTableSheetName) Datatable.ImportSheet path, sheetname, DataTableSheetName c. Datatable.ImportSheet path, sheetname, DataTableSheetName d. None of the above Ans: b 116. What is Regular expression? a. Used in pattern matching of Strings b. Used in pattern matching of Numeric value c. Regular expressions provide tools for developing complex pattern matching d. None of the above Ans: c 117. How to check "L" exists in 'ITeLearn' word? a. InStr("ITeLearn","L") b. Mid("ITeLearn",1) c. InStrRev("ITeLearn","L") d. Left("ITeLearn",3) e. None of the above Ans: a
  • 38. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 118. IT__E_LEARN how to get only 'ITELEARN' using any function a. InStr("IT__E_LEARN","") b. Replace ("IT__E_LEARN","_","") c. Mid ("IT__E_LEARN","_","") d. Right ("IT__E_LEARN","_","") Ans: b 119. How to add 15 days in a date? a. Date ("m", 15, Date) b. Date ("d", 15, Date) c. Date Add ("m", 15, Date) d. Date Add ("d", 15, Date) Ans: d 120. How to get any particular word from a string? a. Using IntStr function b. Using Mid function c. Using Left function d. Using Right function Ans: b 121. What is the use of Trim Function? a. Removes spaces from left of string b. Removes spaces from right of string c. Removes spaces from left and right of string d. None of the above Ans: c
  • 39. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 122. How to Reverse the sting "Welcome to Itelearn"? a. StrReverse("Welcome to itelearn") b. InStrRev("Welcome to itelearn") c. InStr("Welcome to itelearn") d. Reverse("Welcome to itelearn") Ans: a 123. What is Split function? a. Splits string and stores in a variable b. Reverse the string and stores in a array c. Splits string and stores in two dimensional array d. The Split function returns a zero-based, one-dimensional array that contains a specified number of substrings Ans: d Chapter: 4 124. Does QTP support Data Driven Framework? a. No b. Only supports Modular framework c. Yes d. Only supports Keyword driven framework e. None of the above Ans: c
  • 40. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 125. In___ approach tests can be executed multiple sets of test data a. Data Driven Framework b. Modular Framework c. Keyword Driven Framework d. Hybrid Framework Ans: a 126. What is the basic approach of Data Driven Framework? a. Code and Data as a single unit b. Code and Data as separate units c. None of the above Ans: b 127. Which statement is correct to create excel automation object? a. Set objExl = CreateObject("Application.Excel") b. Set objExl = Create("Excel.Application") c. objExl = CreateObject("Excel.Application") d. Set objExl = CreateObject("Excel.Application") Ans: d
  • 41. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 128. Find out the correct option to open a excel file for read or write. a. Set objExl = CreateObject("Excel.Application") objExl.Workbooks.Open ExcelPath b. Set objExl = CreateObject("Excel.Application") objExl.Open ExcelPath c. Set objExl = CreateObject("Excel.Application") objExl.Application.Open ExcelPath d. objExl.Workbooks.Open ExcelPath Ans: a 129. vCellData = mySheet.Cells(Row,Col) This statement will give provided cell data a. FALSE b. TRUE c. Syntax not correct d. None of the above Ans: b 130. mySheet.Cells(Row, Col) = 12 This statement used to write in excel cell a. Syntax Error b. FALSE c. TRUE d. All of the above Ans: c
  • 42. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 131. In Data Driven Framework, data can be only accessed from excel. a. TRUE b. FALSE Ans: b 132. QTP Data table cannot be used in Data Driven Framework. a. FALSE b. TRUE Ans: a 133. Data Driven Framework used for only one set of Test Data a. TRUE b. FALSE Ans: b 134. Which statement correctly used to open any excel sheet? If objExcel object is already created a. Set mySheet = objExcel.ActiveWorkBook.WorkSheets(xlSheet) b. mySheet = objExcel.ActiveWorkBook.WorkSheets(xlSheet) c. Set mySheet = objExcel.WorkSheets(xlSheet) d. Set mySheet=objExcel.WorkSheets("Sheet1") e. Both (a) and (d) Ans: e
  • 43. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 135. How to close active excel sheet using vbscript statement? If objExcel object is already created a. objExcel.close b. activeworkbook.close c. objExcel.activeworkbook.close d. objExcel.activeworkbook.quit e. All of the Above Ans: c 136. ___Statement is used to close excel automation object. If objExcel object is already created a. objExcel.Application.Quit b. objExcel.Close c. Application.Quit d. Application.Close e. None of the above Ans: a 137. ___Statement is used to save modified excel. If objExcel object is already created a. objExcel.save b. objExcel.activeworkbook.save c. activeworkbook.save d. Both (1) and (3) e. All of the Above Ans: b
  • 44. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 138. Following statement is ___."In Data Driven Framework you can not use Descriptive programming" a. TRUE b. FALSE c. Only supports Object Repository d. Data Driven Framework does not Object Repository e. None of the above Ans: b 139. Function libraries concept cannot be implemented in Data Driven Framework. Is it right? a. Yes b. May be c. No d. Both (a) and (b) e. All of the Above Ans: c 140. In Data Driven Framework, can you access data from database? a. Yes b. No c. May be d. all of the Above Ans: a 141. Statement is _____"Data Driven Framework does not support Actions" a. TRUE b. FALSE c. May be d. None of the above Ans: b
  • 45. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 142. Do While xlRead(xlPath, xlSheet, i,1) <> "" statements Loop What this loop will do? xlRead() functions is already defined a. Infinite loop b. will not execute c. Syntax error d. Will read first columns cells for different rows and execute till loop finds a blank cell in excel file e. None of the above Ans: d 143.Does Data Driven Framework supports parallel execution of scripts? a. Yes b. No c. May be d. All of the above Ans: b Chapter: 5 144. ___Statement is used for method overriding in QTP a. RegisterUserFunc b. Method Override c. Class Override d. None of the above Ans: a
  • 46. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 145. RegisterUserFunc statement can also be used for Method reuse a. FALSE b. TRUE c. None of the above Ans: b 146. IsArray is used ____? a. To declare array b. To get length of an array c. To declare dynamic array d. A function indicates whether a specific variable is array or not e. None of the above Ans: d 147. How to join array of substrings? a. By + operator b. By & operator c. Join (Arr) d. All of the above Ans: c 148. In Array, LBound for any dimension is ___ a. 1 b. 0 c. 2 d. 3 e. None of the above Ans: b
  • 47. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 149. ReDim Preserve Arr() In this statement what is the significance of Preserve keyword? a. Preserves the data in an existing array when you change the size of the last dimension b. Removes the data from exiting array and stores new data in array c. Used to Resize the array d. All of the above Ans: a 150. ____ statement is used to size or resize a dynamic array that has already been formally declared using a Private, Public, or Dim statement with empty parentheses a. Dim b. Preserve c. ReDim Preserve d. ReDim e. None of the above Ans: d 151. ____ Reinitializes the elements of fixed-size arrays and deallocates dynamic-array storage space a. Dim b. Erase c. ReDim Preserve d. ReDim e. All of the above Ans: b
  • 48. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 151. How to disassociate an object variable from any actual object a. MyObject = Nothing b. Set = Nothing c. Set MyObject = Nothing d. Set MyObject = Quit e. None of the above Ans: c 152. ___ this is used to size or resize a dynamic array a. Preserve b. ReDim c. Dim d. IsArray e. None of the above Ans: b Chapter: 6 153. Can Descriptive programming be used with Smart Identification? a. Yes b. No Ans: b 154. Which option is correct to create a description object? a. Set myObj = Description.Create() b. Set = Description.Create() c. myObj = Description.Create() d. Set myObj = Description e. All of the above Ans: a
  • 49. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 155. Is it possible to use descriptive programming inside a Checkpoint? a. Yes b. May be c. No Ans: c 156. Which option will provide you number of Edit boxes on a page? a. Set Desc = Description.Create() Desc("micclass").Value = "WebEdit" Set Edits = Browser("Google Sets").Page("Google Sets").ChildObjects() MsgBox "Number of Edits: " & Edits.Count b. Set Desc = Description.Create() Desc("micclass").Value = "Link" Set Edits = Browser("Google Sets").Page("Google Sets").ChildObjects(Desc) MsgBox "Number of Edits: " & Edits.Count c. Set Desc = Description.Create() Desc("index").Value = 0 Set Edits = Browser("Google Sets").Page("Google Sets").ChildObjects(Desc) MsgBox "Number of Edits: " & Edits.Count d. Set Desc = Description.Create() Desc("micclass").Value = "WebEdit" Set Edits = Browser("Google Sets").Page("Google Sets").ChildObjects(Desc) MsgBox "Number of Edits: " & Edits.Count Ans: d
  • 50. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 157. A statement can be combination of both Object repository and Descriptive programming approach a. TRUE b. FALSE c. May be Ans: a 158. ____ stores the properties and values of a particular object in an instance of that object a. Object b. Description Object c.Object Repository d. None of the above Ans: b 159. You cannot use multiple properties to identify an object in DP a. TRUE b. FALSE Ans: b 160. Which approach is followed in this statement Browser("myBro”).page(“myPage”).webbutton(“Enter”).click a. Descriptive Programming b. Object Repository c. Combination of DP and OR d. All of the above Ans: b
  • 51. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 161. Which approach is followed in this statement Browser (“name:=myBro”).page(“title:=myPage”).webbutton(“name:=Enter”,”type:= Submit”).click a. Descriptive Programming b. Object Repository c. Combination of DP and OR d. All of the above Ans: a 162. Which approach is followed in this statement Browser ("myBro").page(“title:=myPage”).webbutton("name:=Login").click a. Descriptive Programming b. Object Repository c. Combination of OR and DP d. None of the above Ans: c 163. How to enable Smart Identification? a. File > Settings b. Tools > Options c. Resources > Object Repository Manager d. Tools > Object Identification > environment > Select object class and on right side you can see "Enable Smart Identification" checkbox selected and few properties under mandatory properties such as name,title etc. Ans: d 164. Smart Identification mechanism uses ____ to identify the objects a. Only Base filter properties b. Only Optional filter properties c. Depends upon situation qtp can use either Base filter or Optional filter properties or combination of both d. All of the above Ans: c
  • 52. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 165. If Smart Identification is used, step is assigned ___ status in test result when no objects match the learned description. a. Passed b. Warning c. Failed d. None of the above Ans: b 166. Enabling Smart Identification always gives correct results a. TRUE b. FALSE Ans: b 167. Can you use regular expressions in Smart Identification? a. No b. Yes c. May be Ans: a 168. What is Quickest Automation Object Model? a. It's a way to write scripts so as to automate your applications b. It's a way to develop frameworks c. Automation Object Model can not be used in QTP d. It's a way to write scripts so as to automate your QuickTest operations e. None of the above Ans: d
  • 53. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 169. How to instantiate QTP? a. Set qtApp = CreateObject() b. Set qtApp = CreateObject("QuickTest.Application") c. qtApp = CreateObject() d. Set = CreateObject("QuickTest") Ans: b 170: Set qtApp = CreateObject("QuickTest.Application") Will this statement launch QTP? a. Yes b. No Ans: b 171. How to launch QTP using AOM? a. Set qtApp = CreateObject("QuickTest.Application") b. qtp.launch c. Set qtApp = CreateObject("QuickTest.Application") qtApp.launch d. None of the above Ans: c 172. How to make QTP visible? a. qtApp.visible = True b. Set qtApp = CreateObject("QuickTest.Application") qtApp.launch c. qtApp.visible d. All of the above Ans: a
  • 54. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 173. How to generate an AOM script with the current QTP settings using QTP? a. File > Settings > Generate script b. Tools > Options c. Tools > Object Identification d. All of the above Ans: d Chapter: 7 174. How do we deal with a dynamic object/continuously changing object at the runtime? a. By Framework b. By Descriptive programming and Ordinal identifier c. By Shared Object Repository d. None of the above Ans: b 175. What is the FireEvent method? a. The FireEvent method is designed to trigger events in an application. e.g onmouseover b. The FireEvent method is designed to handle unwanted errors at run time c. The FireEvent method is designed to trigger application functionalities d. None of the above Ans: a 176. Can you use Regular expression to handle Dynamic Objects? a. Yes b. No Ans: a
  • 55. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 177. ".*" Regular expression can be used to ___. a. Match any single character b. Match zero or more occurrences of the preceding expressio c. Match any character zero or more times d. Match one or more occurrences of the preceding expression Ans: b 178. What are the Ordinal Identifiers? a. An ordinal identifier assigns a numerical value to a test object b. indicates its order or location relative to other objects with an otherwise identical description c. This ordered value provides a backup mechanism that enables QuickTest to create a unique description to recognize an object when the defined properties are not sufficient to do so d. All of the above Ans: d 179. How many types of Ordinal Identifiers are available in QTP? a. Location b. Index c. Creation Time d. All of the above Ans: d 180. In test execution, how to close latest browser opened using QTP? a. Browser("title:=.*").close b. Browser("index:=1").close c. Browser("creationtime:=1").close d. None of the above Ans: c
  • 56. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 181. Regular expressions can be used in Shared Object Repository in QTP to handle Dynamic objects. a. TRUE b. FALSE Ans: a 182. Regular expression [0-9] tells the processor to match any digit in the range of ____ a. Match any digit b. Match any digit between 0 to 9 c. Match only 0 and 9 d. All of the above Ans: b 183. How to create regular expression object in vbscript? a. Set myRegExp = CreateObject("Regexp.Application") b. Set myRegExp = CreateObject("WSShell.Regexp") c. Set myRegExp = New RegExp d. Set myRegExp = CreateObject("Regexp") Ans: c 184. Regular expression ___ matches the preceding character zero or more times a. * b. . (Dot) c. d. .* Ans: a
  • 57. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 185. How to get Tool tip of any link in QTP? a. Can be obtained using only Window("nativeclass:=tooltips_class32").GetROProperty("text") b. By using FireEvent("onmouseover") to simulate mouse placing over the link and then Window("nativeclass:=tooltips_class32").GetROProperty("text") c. Browser("Yahoo!").Page("Yahoo!").WebElement("text:=My Yahoo!").FireEvent "onmouseover" ToolTip = Window("nativeclass:=tooltips_class32").GetROProperty("text") d. Both 2 and 3 Ans: d Chapter: 8 186. What is error handling in QTP? a. If you can predict that a certain event may happen at a specific point in your test or component, it is recommended to handle that event directly within your test or component by adding steps b. Using Recovery Scenario c. Using On Error Resume Next d. All of the above Ans: d 187. If there is error in the code _______ignores it and continue with next line of code. a. Err.Number b. Err.Description c. On Error Resume Next d. On Error Go to 0 Ans: c
  • 58. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 188. ______statement disables error handling. If it is enabled using On Error resume Next a. On Error Go to 0 b. On Error c. Err.Number d. Err.Description Ans: a 189. Err.Number provides ____ a. Description of Error b. Error number c. Disables error handling d. None of the above Ans: b 190. Err.Description provides ____ a. Error number b. Disables error handling c. Description of Error d. All of the above Ans: c 191. When to create Recovery Scenario? a. While executing scripts we may get some Unexpected errors.To recover the test and continue running script from these unexpected errors we use Recovery Scenarios b. To handle known errors or expected errors in the test c. To resume test if any error occurs while executing test d. All of the above Ans: a
  • 59. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 192. In which event you can use Recovery Scenario? a. Application Crash b. Pop up window c. Test Run error d. Object State e. All of the above Ans: e 193. How to open Recovery Scenario manager? a. File > Settings b. Tools > Options c. Resources > Recovery Scenario Manager d. Automation > Record & Run Settings Ans: c 194. A Recovery Scenario consists___ a. Trigger Event b. Recovery Operations c. Post Recovery Test run option d. All of the above Ans: d 195. A function can be called through a Recovery Scenario a. TRUE b. FALSE Ans: a 196. Exist Property with conditional statement can be used to handle errors a. FALSE b. TRUE Ans: b
  • 60. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 197. Environment variables are like ____ a. Local variables b. Global variables c. Can be both d. None of the above Ans: b 198. What Types of environment variables available in QTP? a. Built in b. User defined internal c. User defined external d. All of the above Ans: d 199. _____Variables that represent information about the test on which the test is run, such as Test path and Operating system. These variables are accessible from all tests, and are designated as read-only a. User defined internal b. User defined external c. Built in d. None of the above Ans: c 200. ____ variables that we define within the test. The variables are saved with the test and are accessible only within the test. a. User defined internal b. User defined external c. Built in d. None of the above Ans: a
  • 61. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 201. _____ variables that we predefine in the active external environment variables file.These can be created using a list of variable-value pairs in an external file in .xml format a. User defined internal b. User defined external c. Built in d. None of the above Ans: b 202. Environment.Value(“name”)= “Itelearn”. What is the purpose of this statement in QTP? a. Calling a user defined internal environment variable b. Calling a user defined external environment variable c. Defining an internal environment variable d. Defind a external environment variable Ans: c 203. How to create user defined internal environment variable in QTP? a. File --> settings --> Environment --> select variable type as user defined --> click add icon (+) b. File --> settings --> Environment --> select variable type as user defined --> Browse XML c. Tools --> options --> Environment --> select variable type as user defined --> click add icon (+) d. Resorces --> settings --> Environment --> select variable type as user defined --> click add icon (+) Ans: a
  • 62. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) Chapter: 9 & 10 204. What is Keyword driven framework? a. Where QTP keywords are used to call functions b. Where pre defined keywords are used to describe actions c. In this framework multiple data sets can be used to test d. All of the above Ans: b 205. Which file is mostly used to define keywords for Keyword Driven Framework? a. In Text file b. In Excel file c. In CSV file d. All of the above Ans: b 206. Can manual tester develop tests in Keyword Driven Framework? a. Yes b. No c. May be d. None of the above Ans: a
  • 63. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 207. Can you define different function libraries in Keyword Driven Framework? a. No b. Yes c. May be d. None of the above Ans: b 208. Each keyword related to a function defined in function library. Is this statement True? a. May be b. FALSE c. TRUE d. None of the above Ans: c 209. While Designing Keyword Driven Framework we can map keywords at ___ a. Operation level b. Functional level c. Both Operation and functional level d. None of the above Ans: c 210. Keyword Driven Framework does not support descriptive programming. a. TRUE b. FALSE Ans: b
  • 64. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 211. Does Keyword Driven Framework supports shared object repository? a. TRUE b. FALSE Ans: a 212. In Keyword Driven Framework we mostly use ____ Repository a. Local b. Shared c. None of the above Ans: b 213. What are the common components of Keyword driven framework? a. Excel Sheet to Store the Keywords b. Function Library c. Object Repository d. Test Scripts e. All of the above Ans: e 214. What is Driver script in framework? a. Script is used to initialize and read the control files b. Consists details of all the Test scenarios to be automated. c. Driver Script reads the Test Case files. Checks the keywords and calls the appropriate utility script functions based on specific keyword d. None of the above Ans: c
  • 65. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 215. What are the properties you would use for identifying a browser and page when using descriptive programming? a) Name b) Title c) MicClass d) CreationTime e) All of the above Ans: e 216. There are two browsers opened on your screen. How to close first browser using Descriptive programming? a. Browser("title:=.*").Close b. Browser("Name:=.*").Close c. Browser("CreationTime:=0").Close d. None of the above Ans: c Chapter: 11 217. ____ is the combination of both keyboard driven and data driven frameworks a. Linear Framework b. Hybrid Framework c. Modular Framework d. Keyword Driven Framework Ans: b
  • 66. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 218. In Which case we can design Hybrid Framework a. Rich Application functionality b. Data sensitive testing c. Regression testing d. All of the above Ans: d 219. What are the advantages of Hybrid framework? a. Flexible b. Increases accuracy c. Highest ROI d. All of the above Ans: d 220. Hybrid framework does not support Descriptive programming. a. TRUE b. FALSE Ans: b 221. Different function libraries can be defined in .txt or .vbs files and libraries can be associated to test. a. TRUE b. FALSE Ans: a
  • 67. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 222. Which method you can use to associate function library? a. File > Settings > Resources > Associate Function Library b. Automation Object Model (AOM) c. ExecuteFile Method d. LoadFunctionLibrary Method e. All of the above Ans: d 223. How to associate function library at run time? a. objQTP.Open "C:AutomationSampleTest", False, False Set objLib = objQTP.Test.Settings.Resources If objLib.Find("C:SampleFunctionLibrary.vbs") = -1 Then objLib.Add "C:SampleFunctionLibrary.vbs", 1 End b. objQTP.Open "C:AutomationSampleTest", False, False objQTP.Test.Settings.Resources.Libraries If objLib.Find("C:SampleFunctionLibrary.vbs") = -1 Then objLib.Add "C:SampleFunctionLibrary.vbs", 1 End c. objQTP.Open "C:AutomationSampleTest", False, False Set objLib = objQTP.Test.Settings.Resources.Libraries If objLib.Find("C:SampleFunctionLibrary.vbs") = -1 Then objLib.Add "C:SampleFunctionLibrary.vbs", 1 End d. None of the above Ans: c
  • 68. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 224. In Hybrid framework, data can accessed through database, excel file, xml etc. a. TRUE b. FALSE Ans: a 225. Hybrid framework can be implemented for any application. a. TRUE b. FALSE Ans: a 226. What are the frameworks available other than DDF, KDF and Hybrid? a. Linear Framework b. Modular Framework c. Structured Framework d. All of the above Ans: d Chapter: 12 Topic: Database Testing 227. What is Database Testing? a. Verifying Data Integrity b. Verifying Data Consistency c. Data Comparisons d. Data Back up e. All of the above Ans: e
  • 69. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 228. What is Data comparison? a. Comparing front end data only b. Comparing back end data only c. Comparing front end data with back end or Database table with excel sheet etc d. All of the above Ans: c 229. How to test a SQL Query in QTP? Without using database checkpoints? a.) Pass the Query as a parameter b.) 1)Connect to the database 2)Execute the query 3)Disconnect the connection c. Write a function to execute Query without database connection d. QTP cannot execute SQL Queries e. None of the above Ans: b 230. How to open database connection? a. Set oConnection = CreateObject("ADODB.Connection") oConnection.Open ConnectionString b. Set oConnection = CreateObject("ADODB.Connection") c. CreateObject("ADODB.Connection") d. ConnectionString ="Driver = {SQL Server};Data Source = <>; Server=<>; Database=<>; Trusted_Connection=yes" e. None of the above Ans: a
  • 70. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 231. What is Recordset in terms of Database? a. Recordset also works as a View in Database b. Recordset is a virtual table which stores data c. It is used to open database connection d. The ADO Recordset object is used to hold a set of records from a database table. A Recordset object consist of records and columns Ans: d 232. How to create Recordset object in vbscript? a. Set oConnection = CreateObject("ADODB.Connection") b. Set oRecordSet = CreateObject("ADODB.Recordset") c. ConnectionString ="Driver = {SQL Server};Data Source = <>; Server=<>; Database=<>; Trusted_Connection=yes" d. None of the above Ans: b 233. How to create an ADO SQL recordset? a. set rs=CreateObject("ADODB.recordset") rs.Open "Select * from Customers", oConnection b. Set oRecordSet = CreateObject("ADODB.Recordset") c. set rs=CreateObject("ADODB.recordset") rs.Open "Select * from Customers" d. All of the above Ans: a
  • 71. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) Chapter: 12 Topic: DotNet Factory 234. What is DotNetFactory in QTP? a. DOTNetFactory utility object is something which can be used to work with .Net applications only b. DotNetFactory can be used with web applications only c. Enables QTP scripting to directly access methods and properties of a .NET object by creating an instance of this object d. DotNetFactory can be used with window applications only Ans: c 235. DotNetFactory add-in is required in QTP to use its features. Is this statement correct? a. TRUE b. FALSE Ans: b 236. How to create object instance of DotNetFactory? a. Set oDotNet = CreateObject("DotNetFactory.Net") b. Set oDotNet = DotNetFactory.CreateInstance (TypeName) Type Name: full name of the object c. Set oDotNet = CreateObject("DotNetFactory.Application") d. All of the above Ans: b
  • 72. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 237. How to create object instance of message box? a. msgbox "<>" b. MyMsgBox.Show "!! Hello World !!", "My Custom Message box" c. Set MyMsgBox = DotNetFactory.CreateInstance("System.Windows.Forms.MessageBox", "System.Windows.Forms") d. All of the above Ans: c 238. ____ statement is used to cretae custom user form. a. Set MyForm = DotNetFactory.CreateInstance("System.Windows.Forms.Form", System.Windows.Forms) b. Set MyForm = DotNetFactory.CreateInstance("System.Windows.Forms.MessageBox", "System.Windows.Forms") c. Set MyForm = CreateObject("DotNetFactory.Windows.Form") d. None of the above Ans: a Chapter: 12 Topic: MS Word 239. How to create MS Word object in QTP? a. Set oWord = CreateObject("MSWord.Application") b. Set oWord = CreateObject("MS.Application") c. Set oWord = CreateObject("Application.Word") d. Set oWord = CreateObject("Word.Application") Ans: d
  • 73. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 240. ___ statement is used to make MS Word visible. If Word object is already created. a. oWord.Visible b. oWord.Visible = True c. oWord.Visible = False d. None of the above Ans: b 241. How to add new document in the opened MS Word? If Word object is already created. a. oWord.Documents.Add b. oWord.Add c. oWord.New d. All of the above Ans: a Chapter: 12 Topic: FSO 242. What is FSO? a. An object to create folders only b. An object to create files only c. File System Object is an object to handle text files only d. Filesystemobject is an object model which is used to handle the drives, folders, and files of a system Ans: d
  • 74. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 243. How to create a file? a. First create a FSO object using CreateObject and then create a text file using CreateTextFile b. File can be created directly without creating FSO object c. FSO object can not be used to create files d. None of the above Ans: a 244. ____ statement is used to create FSO object. a. Set fso = CreateObject(“FileSystemObject”) b. Set fso = CreateObject(“Scripting.FileSystemObject”) c. Set fso = CreateObject(“FileSystemObject.Scripting”) d. Set fso = CreateObject(“Scripting.FSO”) Ans: b 245. ____ statement is used to create text file. Assume FSO object is already created. a. Set fso = CreateObject(“Scripting.FileSystemObject”) b. Set file = CreateTextFile(file_location, True) c. Set file = fso.CreateTextFile(file_location, True) d. Set file = CreateObject(file_location, True) Ans: c 246. How to open a file? a. Set file= fso.OpenTextFile("C:file_location", ForReading, True) b. Set file= fso.OpenTextFile("C:file_location", ForAppending, True) c. Set file= fso.OpenTextFile("C:file_location", ForWriting, True) d. All of the above Ans: d
  • 75. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 247. How to read content from a file? a. data = file.ReadLine() b. data = fso.ReadLine() c. data = fso.OpenTextFile("C:file_location", ForReading, True) d. None of the above Ans: a 248. How to write content to a file? a. Set file= fso.OpenTextFile("C:file_location", ForReading, True) file.Write("Welcome to IteLearn.com") b. fso.Write("Welcome to IteLearn") c. Set file= fso.OpenTextFile("C:file_location", ForWriting, True) file.Write("Welcome to IteLearn.com") d. All of the above Ans: c 249. How to delete content? a. fso.DeleteFile b. fso.DeleteFile(file_location) c. file.DeleteFile(file_location) d. None of the above Ans: b Chapter: 12 Topic: Virtual Objects 250. Virtual objects enable you to record and run tests on objects that are normally recognised by QTP. a. TRUE b. FALSE Ans: b
  • 76. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 251. In the test results, the virtual object is displayed as though it is a standard class object. a. TRUE b. FALSE Ans: a 252. QTP does not support virtual objects for _____ recording. a. Analog b. low level c. normal d. Both 1 and 2 Ans: d 253. You can use the object spy to view virtual objects properties. a. TRUE b. FALSE Ans: b 254. You cannot insert any type of checkpoint on a virtual object a. TRUE b. FALSE Ans: a 255. The ____ contains all the virtual object collections defined. a. Virtual Object Manager b. Virtual Manager c. Virtual Object Wizard d. None of the above Ans: a
  • 77. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 256. Extension of virtual object collection files a. .vcf b. .vot c. .vct d. .vcd Ans: b 257. You can remove virtual objects from your test by ___ these objects. a. disabling recognition of b. deleting c. deleting virtual object collection files of d. All of the above e. Both 1 and 2 Ans: e 258. QTP identifies a virtual object according to its ____. a. Properties b. Boundaries c. Object Spy d. Edges Ans: b Chapter: 13 Topic: Shell Scripting 259. How to display a message with some wait time? a. Set wshShell = CreateObject("Wscript.Shell") wshShell.popup "Karthik", 5, "IteLearn" b. Set wshShell = CreateObject("Wscript.Shell") wshShell.msgbox "Karthik", 5, "IteLearn" c. msgbox "IteLearn" d. None of the above Ans: a
  • 78. QTP Interview Questions and Answers Website: http://www.ITeLearn.com Email: learn@itelearn.com Contact: +1-314-827-5272, +91-837-4323-742(India) 260. How to send keyboard inputs? a. Set oShell = CreateObject("WScript.Network") oShell.SendKeys "IteLearn" b. Set oShell = CreateObject("WScript.Shell") oShell.SendKeys "IteLearn" c. WScript.SendKeys "IteLearn" d. All of the above Ans: b 261. How to display current user name of the system? a. Set wshShell = CreateObject("Wscript.Shell") User_Name = wshShell.username b. Set wshShell = CreateObject("Wscript.Network") User_Name = wshShell.user c. Set wshShell = CreateObject("Wscript.Network") User_Name = wshShell.username d. None of the above Ans: c