Ask a Question

help! how to get total row count in Excel File datasource?

SOLVED
Sherry
Not applicable

help! how to get total row count in Excel File datasource?

hi,

I need some help here, I need to get the total row count in a Excel File which is used as DataSource. Does anyone know hot to do that?


Thanks,
Sherry
1 ACCEPTED SOLUTION

Accepted Solutions
georgetjose
Occasional Visitor

Re: help! how to get total row count in Excel File datasource?

To get the total number of rows in the Excel.

def rowCount = testRunner.testCase.getTestStepByName('DataSource').rowCount;

or

def rowCount =testRunner.testCase.testSteps["DataSource"].rowCount;

 

Note: Assuming that DataSource is the name of the Step.

 

View solution in original post

2 REPLIES 2
georgetjose
Occasional Visitor

Re: help! how to get total row count in Excel File datasource?

To get the total number of rows in the Excel.

def rowCount = testRunner.testCase.getTestStepByName('DataSource').rowCount;

or

def rowCount =testRunner.testCase.testSteps["DataSource"].rowCount;

 

Note: Assuming that DataSource is the name of the Step.

 

View solution in original post

Olga_T
Moderator

Re: help! how to get total row count in Excel File datasource?

Hi all,

 

Thanks for the reply, @georgetjose !

 

@Sherry, is this what you were looking for?


Olga Terentieva
SmartBear Assistant Community Manager

cancel
Showing results for 
Search instead for 
Did you mean: 

Join the Community

Ask Community Experts

Join more than 100,000 users worldwide. Ask questions, request features, post replies, award kudos, and more.

Join Now For Free

Already a member? Sign In