nanda.d reddy


{ City } bangalore
< Country > india
* Profession *
User No # 6256
Total Questions Posted # 1
Total Answers Posted # 107

Total Answers Posted for My Questions # 5
Total Views for My Questions # 9071

Users Marked my Answers as Correct # 292
Users Marked my Answers as Wrong # 124
Answers / { nanda.d reddy }

Question { DST Global Solutions, 7824 }

When there is descriptive programming, why do we go for
Object repository for desigining scripts.?? why cant we use
descriptive programming instead of using the Object
repository..??


Answer

and also..

writing the script will take more time when writing in
DP. maintance of the script will be difficult.
if some of the object properties are changing from
build to build u have to update same in script also. but if
u are using Object Repository u can update those property
values in Object Repository. its one time change.or u can
handle this in object repository with reguler expression.

like this we can say many examples.

if any queries:
nanda.dreddy@gmail.com

Is This Answer Correct ?    1 Yes 1 No

Question { DST Global Solutions, 7082 }

Can you give me the code to calculate the total number of
Links using the child object in the web page..? is there
any other way to calculate number of links with out using
the Child objects.??


Answer

Hi Uday,

its nice answer. keep it.

and also u can use html tag instead of micclass..

like

linkDescObj("html tag").value="A"

it will perform same functionality.

Is This Answer Correct ?    3 Yes 0 No


Question { Livetek, 4482 }

How should i get name of the screen?
Ex:There is a "submit" button.If i clicked on the submit
button it opens a screen. I want that screen name.How can i
get that screen name
I dont have any property regarding that screen.
If suppose we cliked on the screen , Then QTP captures the
screen properties
then i can get the screen name by using GETROPROPERTY
But i want the screen name without clicking the screen.
("I am using the "settoproperty" for Second screen by using
fist screen properties")
Please tell me anyone


Answer

is that screen is Browser or Window?

If it is Browser..

If Browser("Creationtime:=1").Exist(10)Then
g = Browser("Creationtime:=1").GetROProperty("name")
msgbox g
End If

If possible can send that screenshot of that screen to:

nanda.dreddy@gmail.com

Is This Answer Correct ?    1 Yes 0 No

Question { IBM, 9285 }

How do we edit the script in QTP. Anybody can explain in
detail..Thanks in advacne...


Answer

Hi,

Can u tell me which process u r following in ur company.
are u saving the scripts in Actions or maintaining the
scripts in functional leavel.

....Nanda

Is This Answer Correct ?    0 Yes 0 No

Question { 3727 }

I am trying to read the rediffmail usign the below code. But
facing problem, while i user to get the link of the mail, i
am getting all the link of the page, While i just want to
get only mail name - link (not all the link of an page) so
that i able to read the mail message by clcking on them in qtp.

Dim Lnk,Webcheckbox
Set Lnk= Description. Create
'********* To count and display the webcheckbox
Lnk("micclass" ).value=" Link"
set LinkName= Browser("Welcome to Rediffmail:"
).Page("Welcome to Rediffmail:" ).ChildObjects( Lnk)
LinkCount=LinkName. Count
msgbox LinkCount
For i=1-1 to LinkCount-1
DataTable.SetCurren tRow(i)
DataTable.Value( "Name",1) =LinkName( i).GetRoProperty ("name")
Next
Waiting for the reply
Praveen Saini


Answer

Hi Praveen..

try to filter the links by table wise or frame wise.

i think inbox will be a table( Rediff is blocked here, i
can not check).

check like this...

set LinkName = Browser().page().Table().ChildObjects()..

here table is inbox. so u will get the links which are only
in inbox.


if any queries...

Nanda.dreddy@gmail.com

Is This Answer Correct ?    1 Yes 0 No

Question { IBM, 6408 }

examples of user definied functions? how to write user
defined functions in qtp9.2?


Answer

see..u can write user defined function in many ways.

here i am explaing u one sample example.

Public Function Func_Login(strUser,strPassWord)

Browser().Page().WebEdit("Name:=UserID").set strUser
Browser().Page().WebEdit("Name:=Password").setSecure
crypt.encrypt(strPassword)
Browser().Page().WebButton("Name:=Log In").Click

End Function

When ever u want to login to application u can call this
function with parameter values for User and Password.

Example:
sUser = DataTable.Value("UserName")
sPassword = DataTable.value("Password")

' Call the Login function for loggin in to application..

Func_Login sUser,sPassword

Note : the function can not contain Object repository. So
before calling or executing this function u have to
associate Object repostiroy to the Current Action where
this function is called. And also should assoicate the
function library file where this function is stored.

If any queries..

nanda.dreddy@gmail.com

Is This Answer Correct ?    3 Yes 1 No

Question { Tech Mahindra, 11212 }

We need to verify the user name & password in for the user
validation. But we don't want to use the parameterization/
loop for user name and password. What is the way in
scripting so that user & password will generate automatically.


Answer

Aparna u are correct..but he doesnt want parameterization.
thats what i mentioned in the above answer. if u generate
random number and passing that to user name and password,
it is one of the parameterization techique. Am i correct?
and another way is u can take the values
from environment, but this is also one of the
parameterization.

Is This Answer Correct ?    3 Yes 0 No

Question { 3978 }

Hi All,

I am a beginner in QTP and have understood the basics of QTP
by going through tutorial.
I am trying to Automate a HRMIS application, What is the
right approach to Automate this application. Kindly answer.

Thanks in advance


Answer

Hi dude,

the approach will be..

1 . First Identify the scenarios and test cases to be automated.
2. Do naming conventions to all scenarios.
3. Separate the Reusable scenarios, which we can use across
in all modules. and module specific scenarios.
4. Prepare the test data.
5. Now come to QTP, Identify the install the add in, that
application supports. For Example: Application is developed
with Java, Add in should be Java.
6. Capture required objects to Object Repository (some times
u have to Descriptive also), and save that object repository
as shared repository(do this by using repository manager
window, not with repository window).
7. Associate the shared repository to test.
8. Take one scenario, which is identified to automate in step 1.
9. Paste the required test data in Data Table( Data table
will be used only in basic level, in general it will be in
external excel sheet)
10. Use Environment variables to store global
variables(Global variables means which can be used in all
the scripts, by all the testers and in all environments).
These variables should be stored in external XML file. and
later u have to import that XML file in to script.
11. Write the script for each step by step. for validation
of every step use exist method, getROProperty and Different
types of operators.
12. make sure that each script should contain only one test
case or scenario.
13. If scenario is reusable, then make that automation
script as reusable.
14. if u r using some lines of script many more times, it is
better to put those script in functions.
15. Do not use any checkpoints.
16. If u r getting any unexpected pop ups use recovery
manager, else do not.

you told u are still basic, so these steps are enough for
u now.

If you get any doubts, mail me at:
nanda.dreddy@gmail.com by referring the URL of this
question.

Regards...
Nanda.D Reddy

Is This Answer Correct ?    0 Yes 0 No

Question { 6320 }

Hi all please solve this.It is urgent.....
When I right clicked on a Web image manually It displayed
Open link,open link in new window,save picture as, Email
picture,Printpicture,propeties...etc.
While automation I have written a code like this
'browser("Google").Page("ramseeker®: Memory and_3").Image
("graphOfModel").Click 10,10,micRightBtn
But the right click menu was not displayed.
I want to save that image in a seperate folder


Answer

Hi Dude,
if you want to save that image use capturebitmap
method...


Browser("XXXXX").Page("XXXXX").CaptureBitmap ""

ex:

Browser("XXXXX").Page("XXXXX").CaptureBitmap "C:\sample.bmp"


you give only bmp.

if you didnt get answer please mail at:

nanda.dreddy@gmail.com

Is This Answer Correct ?    1 Yes 0 No

Question { 4427 }

When testing a web application, the url for each page
changes, so using QTP how do u handle this scenario. If
anyone knows please answer in detail about the whole
procedure. Thanks a lot.


Answer

may be u want to say the page title will chage, due to that
script fails?
if it is ur situation:

use the regular expression for page title property in
Object repository. it will handle ur scenario.

regular expression will be : .* , this will be matched to
any value, so that QTP will recogninze the page even the
titles are changing dynamically.

if u didnt get this please mail at: nanda.dreddy@gmail.com
by reffrening this question.

Is This Answer Correct ?    2 Yes 0 No

Question { 11437 }

What is the use of "Define new test object" in QTP 9.1
When should we use? Explain?


Answer

By using 'Define new test object' we can create a new test
object in object repository, even the application is not
available.

Is This Answer Correct ?    3 Yes 0 No

Question { 11437 }

What is the use of "Define new test object" in QTP 9.1
When should we use? Explain?


Answer

yeah good question...

in some situations we have to prepare the scripts before
the application is delivered for testing. at that time you
can not capture the objects from application, right? so,
what you can do is you can create the test objects manually
based on the test case says, and can prepare the scripts.
once the application is ready we will debug the script to
check whether QTP is identifying the objects with the user
defined test object description. if not identifying u can
change the properties of those objects.

and another situation, when you are capturing some
objects to Object Repository some of the objects may be
invisible. they will come to visible only in some
situations. so, you will create one user defined test
object even that object is invisible.

may be this can answer your question, if not please
reply me again. i can add some more description.

Is This Answer Correct ?    3 Yes 0 No

Question { Cap Gemini, 6136 }

I have to automate webpage. If I click one hyperlink2 it
will take 2 hrs to open. How to automate hyperlink2?


Answer

if it is taking that much time...i suggest you not automate
that. if you still wants to automate u can use wait
statement to wait for that much time.


else use loop to wait until that page exist.
for example:

i = 0

do while i <=10

If Browser("XXX").Page("XXXX").Exist Then
Exit Do
Else
Wait 40
End If

i = i+1

Loop


If any queries mail me at :
nanda.dreddy@gmail.com

Is This Answer Correct ?    2 Yes 2 No

Question { Polaris, 6135 }

. My application is updating the user information in the
application. Every time it is Adding on record in my
application and Validating the information like “Record has
added successfully”. Which Check point I have to put in
this situation? Why?


Answer

if u want to use checkpoints in script...u can use text
checkpoint here....why because...text checkpoint verifies
for some text whether that text is displayed in specified
location or not.

Is This Answer Correct ?    3 Yes 0 No

Question { Polaris, 4505 }

How many function you use in your application?


Answer

hey dude...

how many means....no body can tell exact number.

we will use n number functions in the script...it includes
builtin functions and user defined functions.

Is This Answer Correct ?    14 Yes 0 No

Prev    1   2   3   4   5   6    [7]   8    Next