How will you set a unique four digit number in an edit
field in QTP?

Answers were Sorted based on User's Feedback



How will you set a unique four digit number in an edit field in QTP?..

Answer / tvs ramakrishna chowdary

we can set 4 digit no in edit box field dynamically
-----------------------------------------------------
let assume password edit box is there
----------------------------------------
str="rama"
no=randomnumber(1000,10000)'here we are generating random
value between 1000,10000

pwd=str&no
password=crypt.encrypt(pwd)
objectheirarchy.edit("password").setsecure pwd

Is This Answer Correct ?    6 Yes 2 No

How will you set a unique four digit number in an edit field in QTP?..

Answer / bashur

using environment variable
you can write XML script to define environment variable in
notepad and save it as XML file.and when u executing qtp
main script call this environment variable.

Is This Answer Correct ?    4 Yes 2 No

Post New Answer

More QTP Interview Questions

What is the use of Regular expression?

5 Answers  


What is throw object?

0 Answers  


can we test an windows application using qtp

1 Answers  


any one can explain about QTP proocess,means where to start and how to start Scripting.

3 Answers  


Explain runtime dynamic settings?

0 Answers  






How to export quicktest professional results to an .xls file?

0 Answers  


I am trying to install QTP 9.5 but i am getting error message saying that ("Path is \QuickTest Professional\bin\vb_init.exe") vb_init.exe file is not find. can anybody give me the advise what to do ?

0 Answers  


how can we perform web datatable operations on webpages(Like rowcount,col count,cell data)?

2 Answers   Syntel,


Write a QTP script to enter a keyword in to Google search engine?

0 Answers   Wells Fargo,


how to identify a webtable coulmn values ,if we spy the coulmn value it is sometimes identifying as Webedit and some times it is identifying as "webelement", Could any body let me know how to handle the issue?

1 Answers  


Is it possible to merge two object repository files in qtp?

0 Answers  


In My application, having Copmany Name : Text Box and click Save button. if i enter a vlue, after run..........it shows the already exists. so how to enter random ro mmultiple names names into webedit box(company Name). without using DATATABLE THanks Ramesh

4 Answers   TCS,


Categories