Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...


If i entered 2 columns and 4 rows inputs in DDT Like Mango
fruit, Banana Fruit, Brinjal Veget, Carrot Veget.. . My Q
is How to get the 2nd column value for corresponding 1
column input in 3rd row ie, ( i need to get "veget" in
messge box @ run time

Answers were Sorted based on User's Feedback



If i entered 2 columns and 4 rows inputs in DDT Like Mango fruit, Banana Fruit, Brinjal Veget, Car..

Answer / satya

strCnt=DataTable.getRowsCount
For i=1 to strCnt
datatable.SetCurrentRow(i)
x=datatable.Value("A")
datatable("c")=x
Next

Is This Answer Correct ?    4 Yes 0 No

If i entered 2 columns and 4 rows inputs in DDT Like Mango fruit, Banana Fruit, Brinjal Veget, Car..

Answer / ratna

datatable.setcurrentrow(3)

x=datatable.value(2,1)

'datatable.value(2,1) where 2 is column name and 1 is sheet
no. ie., 1 is for global sheet

msgbox x

'output is veget

Is This Answer Correct ?    2 Yes 0 No

If i entered 2 columns and 4 rows inputs in DDT Like Mango fruit, Banana Fruit, Brinjal Veget, Car..

Answer / sampath

datatable.SetCurrentRow(3)
x=datatable.Value("A",1)
msgbox x
datatable.Value("c",1)=x
msgbox c

--------------------------------------
A c
mango
banana
brinjal
carrot

Is This Answer Correct ?    5 Yes 5 No

If i entered 2 columns and 4 rows inputs in DDT Like Mango fruit, Banana Fruit, Brinjal Veget, Car..

Answer / ravi

Ratna...Could u pls explain your answer

Is This Answer Correct ?    0 Yes 0 No

If i entered 2 columns and 4 rows inputs in DDT Like Mango fruit, Banana Fruit, Brinjal Veget, Car..

Answer / saff

i= inputbox "enter ur string" # say brinjal

r=datatable.getrowcount #get row count
for i=1 to r #loop till the end of the row
datatable.setcurrentrow(i)
aa=datatable.(a ,dtglobalsheet) # column 1 value into aa
if instr(aa,i,1)=1 #compare the strings
bb=datatable(b,dtglobalsheet)
msgbox bb
exit
else
i=i+1
next

Is This Answer Correct ?    0 Yes 1 No

Post New Answer

More QTP Interview Questions

HI How to take screenshots of a Webpage and saving it in a external word document using QTP.

4 Answers   3i Infotech, TCS,


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

3 Answers  


How many tabs are available in debug viewer pane?

0 Answers  


How to call the userdefined functions to script? If i am stored 'add()' function in Library functions folder. i want to cal that function in my script.

4 Answers  


I Selected for TCS-Chennai(Contract to hire) position plz suggest me whether i have to join or not

2 Answers   TCS,


Error handling

3 Answers   Wipro,


I'm having a problem to get the status(pass or fail) during runtime for every iteration ran, and must get the results stored to an excel sheet if possible.

1 Answers   FAI,


Is text area check point supports for web applications?

0 Answers  


PLZ EXPLAIN HOW TO LAUNCHING QTP IN TEST DIRECTOR? Is it possible or not? If No Why we r using qtp Td Combination? plz explain briefly? What is the purpose of TD With QTP?

1 Answers   Wipro,


how do we know whether all objects are stored in the object repository or not? how can we know if a particular object is not stored in the repository?

0 Answers  


images are dynamically changes how to compare two images

2 Answers   Hexaware,


what is smart identification?

1 Answers  


Categories