In this session you will more about Excel reading concepts
// 1. Getting Number of Columns And Getting the Column Name ( Header Names )
// 2. Printing all the values from the Column
// 3. Storing Values in to Variables to pass to the Web Applications for testing.
Example Program at the end
𝐃𝐨 𝐲𝐨𝐮 𝐰𝐚𝐧𝐭 𝐭𝐨 𝐥𝐞𝐚𝐫𝐧 𝐒𝐞𝐥𝐞𝐧𝐢𝐮𝐦 𝐀𝐮𝐭𝐨𝐦𝐚𝐭𝐢𝐨𝐧 𝐢𝐧 𝐯𝐞𝐫𝐲 𝐞𝐚𝐬𝐲 𝐰𝐚𝐲 ?
Learn Selenium in easy way by dividing the concepts in to Module wise. Below are the list of Modules wise learning, each contains max 4 to 5 videos that you can complete in 1 or 2 days.
🅽🅾🆃🅴
You have all practice programs pasted in the description on each video.
You have GitHub Repository where all the programs are stored at one place for your practice.
Links pasted at the end
𝐘𝐨𝐮 𝐜𝐚𝐧 𝐣𝐨𝐢𝐧 𝐛𝐞𝐥𝐨𝐰 𝐆𝐫𝐨𝐮𝐩 𝐟𝐨𝐫 𝐦𝐨𝐫𝐞 𝐮𝐩𝐝𝐚𝐭𝐞𝐬 𝐚𝐧𝐝 𝐟𝐨𝐫 𝐜𝐨𝐥𝐥𝐚𝐛𝐨𝐫𝐚𝐭𝐢𝐨𝐧
/ 4754296501308288
𝐈𝐟 𝐲𝐨𝐮 𝐰𝐚𝐧𝐭 𝐭𝐨 𝐝𝐢𝐬𝐜𝐮𝐬𝐬 𝐨𝐫 𝐬𝐡𝐚𝐫𝐞 𝐨𝐫 𝐠𝐚𝐢𝐧 𝐤𝐧𝐨𝐰𝐥𝐞𝐝𝐠𝐞 𝐨𝐫 𝐭𝐫𝐨𝐮𝐛𝐥𝐞𝐬𝐡𝐨𝐨𝐭 𝐈𝐬𝐬𝐮𝐞𝐬 𝐛𝐲 𝐭𝐚𝐤𝐢𝐧𝐠 𝐡𝐞𝐥𝐩 𝐣𝐨𝐢𝐧 𝐭𝐡𝐞 𝐛𝐞𝐥𝐨𝐰 𝐅𝐨𝐫𝐮𝐦
https://chat.whatsapp.com/Drhb7GEZcrA...
𝐒𝐞𝐥𝐞𝐧𝐢𝐮𝐦 𝐌𝐨𝐝𝐮𝐥𝐞 - 𝟏 𝐏𝐥𝐚𝐲𝐥𝐢𝐬𝐭
/ playlist. .
𝐒𝐞𝐥𝐞𝐧𝐢𝐮𝐦 𝐌𝐨𝐝𝐮𝐥𝐞 - 𝟐 𝐏𝐥𝐚𝐲𝐥𝐢𝐬𝐭
/ playlist. .
𝐒𝐞𝐥𝐞𝐧𝐢𝐮𝐦 𝐌𝐨𝐝𝐮𝐥𝐞 - 𝟑 𝐏𝐥𝐚𝐲𝐥𝐢𝐬𝐭
/ playlist. .
𝐒𝐞𝐥𝐞𝐧𝐢𝐮𝐦 𝐌𝐨𝐝𝐮𝐥𝐞 - 𝟒 𝐏𝐥𝐚𝐲𝐥𝐢𝐬𝐭
/ playlist. .
𝐒𝐞𝐥𝐞𝐧𝐢𝐮𝐦 𝐌𝐨𝐝𝐮𝐥𝐞 - 𝟓 𝐏𝐥𝐚𝐲𝐥𝐢𝐬𝐭
/ playlist. .
𝐒𝐞𝐥𝐞𝐧𝐢𝐮𝐦 𝐌𝐨𝐝𝐮𝐥𝐞 - 𝟔 𝐏𝐥𝐚𝐲𝐥𝐢𝐬𝐭
/ playlist. .
𝐒𝐞𝐥𝐞𝐧𝐢𝐮𝐦 𝐌𝐨𝐝𝐮𝐥𝐞 - 𝟕 𝐏𝐥𝐚𝐲𝐥𝐢𝐬𝐭
/ playlist. .
𝐒𝐞𝐥𝐞𝐧𝐢𝐮𝐦 𝐌𝐨𝐝𝐮𝐥𝐞 - 𝟖 𝐏𝐥𝐚𝐲𝐥𝐢𝐬𝐭
/ playlist. .
𝐂𝐨𝐫𝐞 𝐉𝐚𝐯𝐚 𝐁𝐚𝐬𝐢𝐜 𝐂𝐨𝐧𝐜𝐞𝐩𝐭𝐬 𝐏𝐥𝐚𝐲𝐥𝐢𝐬𝐭
/ playlist. .
𝐎𝐎𝐏𝐒 𝐂𝐨𝐧𝐜𝐞𝐩𝐭𝐬 𝐏𝐥𝐚𝐲𝐥𝐢𝐬𝐭
/ playlist. .
𝐅𝐫𝐚𝐦𝐞𝐰𝐨𝐫𝐤 𝐏𝐫𝐞-𝐫𝐞𝐪𝐮𝐢𝐬𝐢𝐭𝐞𝐬
/ playlist. .
𝐆𝐢𝐭𝐇𝐮𝐛 𝐑𝐞𝐩𝐨 𝐟𝐨𝐫 𝐒𝐞𝐥𝐞𝐧𝐢𝐮𝐦 𝐁𝐚𝐬𝐢𝐜 𝐏𝐫𝐨𝐠𝐫𝐚𝐦𝐬 𝐏𝐫𝐚𝐜𝐭𝐢𝐜𝐞
https://github.com/knowledgeshare.../...
𝐆𝐢𝐭𝐇𝐮𝐛 𝐑𝐞𝐩𝐨 𝐟𝐨𝐫 𝐒𝐞𝐥𝐞𝐧𝐢𝐮𝐦 𝐅𝐫𝐚𝐦𝐞𝐰𝐨𝐫𝐤 𝐝𝐞𝐬𝐢𝐠𝐧 𝐜𝐨𝐧𝐜𝐞𝐩𝐭𝐬
https://github.com/knowledgeshar.../f...
𝐆𝐢𝐭𝐇𝐮𝐛 𝐑𝐞𝐩𝐨 𝐟𝐨𝐫 𝐂𝐨𝐫𝐞 𝐉𝐚𝐯𝐚 𝐩𝐫𝐨𝐠𝐫𝐚𝐦𝐬 𝐩𝐫𝐚𝐜𝐭𝐢𝐜𝐞
https://github.com/knowledgeshare-tec...
package excelRead_Write;
import java.io.File;
import java.io.FileInputStream;
import java.io.FileNotFoundException;
import java.io.IOException;
import org.apache.poi.xssf.usermodel.XSSFCell;
import org.apache.poi.xssf.usermodel.XSSFRow;
import org.apache.poi.xssf.usermodel.XSSFSheet;
import org.apache.poi.xssf.usermodel.XSSFWorkbook;
public class ReadExcelUsingColumnNames {
public static void main(String[] args) throws IOException
{
File file=new File(System.getProperty("user.dir") + "\\TestData\\" + "Regression_TestData" + ".xlsx");
FileInputStream inputstream=new FileInputStream(file);
XSSFWorkbook wb=new XSSFWorkbook(inputstream);
XSSFSheet sheet=wb.getSheet("LoginDetails");
// 1. Getting Number of Columns And Getting the Column Name ( Header Names )
// 2. Printing all the values from the Column
// 3. Storing Values in to Variables to pass to the Web Applications for testing.
// 1. Getting Number of Columns
//UnComment below Code
// Getting Column Count and Printing Columns Nmaes ( to read the value using Column Names later )
/*
XSSFRow row=sheet.getRow(0);
// Getting the Column Count int Column_Count=row.getLastCellNum();
System.out.println("Column Count is : "+ Column_Count); XSSFCell cell=null;
// Getting Column Names for (int i=0;iLTColumn_Count;i++) {
cell=row.getCell(i); String Column_Name=cell.getStringCellValue();
System.out.println("Column Name is : " + Column_Name); }
*/
// UnComment below Code
// Printing all Values from all rows and all Columns
/*
XSSFRow row=null; XSSFCell cell=null;
for(int i=0;iLT=sheet.getLastRowNum();i++) //Navigate through the Row {
row=sheet.getRow(i);
for(int j=0;jLTrow.getLastCellNum();j++) // Navigate through the Columns {
cell=row.getCell(j); String my_cell_value=cell.getStringCellValue();
System.out.println("My Cell value is : " + my_cell_value); } }
*/
// Storing Values in to Variables ( In this case, Usernames and Passwords )
XSSFRow row=null;
XSSFCell cell=null;
String userName=null;
String password=null;
for (int i=1; iLT=sheet.getLastRowNum();i++)
{
row=sheet.getRow(i);
for ( int j=0;jLTrow.getLastCellNum();j++)
{
cell=row.getCell(j);
if(j==0) // We can use Column Name as well, will see in upcoming sessions
{
userName=cell.getStringCellValue();
}
if(j==1) // We can use Column Name as well, will see in upcoming sessions
{
password=cell.getStringCellValue();
}
}
System.out.println("User Name : " + userName + " ---- " + "Password : " + password);
// We can pass this values in to web application for testing Test user Accounts.
}
}
}