Micro Focus QTP (UFT) Forums
QTP Scription Question - Printable Version

+- Micro Focus QTP (UFT) Forums (https://www.learnqtp.com/forums)
+-- Forum: Micro Focus UFT (earlier known as QTP) (https://www.learnqtp.com/forums/Forum-Micro-Focus-UFT-earlier-known-as-QTP)
+--- Forum: UFT / QTP Beginners (https://www.learnqtp.com/forums/Forum-UFT-QTP-Beginners)
+--- Thread: QTP Scription Question (/Thread-QTP-Scription-Question)



QTP Scription Question - Manish - 01-15-2009

Hello All,
I would really appreciate if some of you guru’s could clear up a few conceptual thing (doubts) which I’ve not been able to understand in QTP. Just letting you all know that I’m new to testing and trying to learn QTP.
My main concern is (or the thing I’ve not understood) is mainly the scripting part in QTP. From what I understood after reading many of the posts in this forum is that I can write scripts (in Expert View) and use them for testing the page. Now my questions to you guys are:
1. Is this manually written script the same as what QTP generates when I record the tests? As I understand is that script is written only in Expert View Window. Please let me know if I’m missing something over here.
2. If I’m writing the scripts manually is there a way I could see the context sensitive help for what I’m typing and is there a way I can find out what parameters / and the values could be passed to the calling function e.g. I’ve seen Browser function/method being used a lot but when I type in browser that does not bring the context sensitive help nor does it tell me the parameter list I can pass to it. Or if there is some help file which tells me about the function parameters that would solve my problem.
browser("title:=Yahoo.*").page(ParameterOverHere?)…….
3. What is the best way to learn how to write script or where do I start for writing scripts is there a tutorial for doing it like we have a tutorial by HP and learning QTP?
I appreciate your time and answers.

Thanks


RE: QTP Scription Question - kishoreinchennai - 01-15-2009

1. Is this manually written script the same as what QTP generates when I record the tests? As I understand is that script is written only in Expert View Window. Please let me know if I’m missing something over here.
When you record an action say you type qtp in google these are the things happen"

a)the text field is added in the object repositary
b) a script is created say
Code:
"Browser("").Page("").webedit("").set "qtp"

writting scripts is
you can now do the same by manually typing the above code in expert view
for context help to work the object need to be in the repositary

anothere approach is descriptive programming where u do everything descriptively you dont need a object repositary.


2. If I’m writing the scripts manually is there a way I could see the context sensitive help for what I’m typing and is there a way I can find out what parameters / and the values could be passed to the calling function e.g. I’ve seen Browser function/method being used a lot but when I type in browser that does not bring the context sensitive help nor does it tell me the parameter list I can pass to it. Or if there is some help file which tells me about the function parameters that would solve my problem.
Code:
browser("title:=Yahoo.*").page(ParameterOverHere?)…….
3. What is the best way to learn how to write script or where do I start for writing scripts is there a tutorial for doing it like we have a tutorial by HP and learning QTP?
any basic book on vbscripting
I appreciate your time and answers.