When importing an excel file that has several columns each
with different number of rows into QTP's Global datatable,
how can you count the number of rows in a particular column?

Answer Posted / pushkar1206

datatable.ImportSheet "C:UserspushkarDesktop123.xls","Sheet1","Action1"
rw=datatable.GetSheet("Action1").GetRowCount
For i=1 to rw
a=datatable.GetSheet("Action1").GetParameter("_11").ValueByRow(i)
c=len(a)
If c>0 Then
b=b+1
End If
Next
msgbox b

Is This Answer Correct ?    1 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is event handling in vbscript?

593


what is the features of visual basic?

1550


How to find the font in qtp. Scenario:After entering the username and passwd you will be navigate into the "welcome:Username" page.Now I want to extarct font for this message.

1738


What is difference between vbscript and vba?

606


What are class properties?

650






Explain sga memory structures?

577


What's the difference between vbscript and vb.net?

550


How to make sure that items in a wintree are sorted al?

2352


1) How can we use VB script in testing the application? 2) What all are the things(Software application to be installed in PC) we need to learn VBscript?

3551


1. How to handle object implementation change in DP for Ex: i have login page with username,pasword (editboxes),login,cancel(buttons). Here i written DP code for login page with the help properties. My questions: 1.If properites are changing dynamically i will do (i want code for that) 2.if objects are changed dynamcally i will do (i wnat code for that)

1611


Explain vbscript in detail?

615


How will you convert a string to upper case string using vbscript?

551


can anyone tell me the procedure of interview held in applabs

1746


write a function to read the items from combobox of Flight reservation & save in excel (QTP)??

2391


what do you mean .ota mobile format

1937