Contributions
Re: How can I Count the row of test data in my excel sheet.
kaiiii You can use follwoing groovy script to get number of rows in an excel sheet- --------------------------------------------------------------------------------------------- import com.eviware.soapui.support.XmlHolder import jxl.* import jxl.write.* // DECLARE THE VARIABLES def myTestCase = context.testCase //myTestCase contains the test case def size Workbook workbook1 = Workbook.getWorkbook(new File("C:\\Users\\sethir\\files\\numbers.xls")) //file containing the data Sheet sheet1 = workbook1.getSheet("orders")// You can also provide 0 instead of sheet name. It will read first sheet from the workbook size= sheet1.getRows().toInteger() //get the number of rows, each row is a data set log.info ("total rows"+ size);1.5KViews1like2Comments