Interview Questions

Selenium WebDriver - How do you read data from excel ?

Selenium WebDriver Interview question and Answers


(Continued from previous question...)

Selenium WebDriver - How do you read data from excel ?

FileInputStream fis = new FileInputStream(“path of excel file”); Workbook wb = WorkbookFactory.create(fis); Sheet s = wb.getSheet(“sheetName”); String value = s.getRow(rowNum).getCell(cellNum).getStringCellValue();
FileInputStream fis = new FileInputStream(“path of excel file”);
Workbook wb = WorkbookFactory.create(fis);
Sheet s = wb.getSheet(“sheetName”);
String value = s.getRow(rowNum).getCell(cellNum).getStringCellValue();

(Continued on next question...)

Other Interview Questions