This video is much better than naveen automation cos you covered many scenarios like scrapping all data, clicking from list or clicking directly using reversed customized XPath. Keep it up. Can you pls create video how we can compare two workbooks? Or how can we take webtable data in excel?
Hey Mukesh. it was a good explanation in this video. I'd like to know how you handle cases where you need to write a generic method, using some string, in order to make some operation on specific data in the table. In the video, you show the use of specific elements...
Hi Sir, Thanks a lot for the video... it is currently helping me during interview process as this topic is very important. I just had one small query: Below is the example where you have declared two lists one for getting the row elements and one for getting the data. cant we use only one list as { List rowdata=driver.findElements(By.xpath("//table[contains(@id,'cust')]//tr/td")) } instead of the below two lits List rowli=driver.findElements(By.xpath("//table[contains(@id,'cust')]//tr"));
List rowdata=driver.findElements(By.xpath("//table[contains(@id,'cust')]//td"));
Hi Mukesh, Is there a way to handle AG-Grid using serenity framework or any Java testing framework. If yes, could you please make one video on that or could you please let us know any documentation on that.
1.Thank u for helping me a lot but mukesh how can we compare those table values with excel data table that means assume in case if we have download xl button then xl will download 2.so we need to compare same table data with excel data can u pls help me about that or else can u pls make a single video pls mukesh atleast one video is enough
hii mukesh it was very good explanation I have one doubt in one student table some students are failed some of them passed I want failed student Alldata like phone number, mail id Please explain this topic once thank u
Hi Mukesh, I want to find the some text from 1st column and then I want to click on the link which is present on next column in same row. What logic we can use here, can you please suggest.
Thanks for the covered important topic. But still you are using indexing in xpath then how it comes the under dynamic. In future if any row or column added in table those xpath will not work right?
Hi Sir, how to get the location for any specific data? ex: I need to check in which row or column India is appearing in case if the txt is dynamic. plz help
This is heavy lines of code and more weight to the class file.. we can achieve it with simple one dynamic XPath if we are looking for one specific data validation or multiple..just a thought 😉.. thanks for the info
when I add @Test ,I get the error...Error: Main method is not static in class practise.SeleniumPractise, please define the main method as: public static void main(String[] args)or a JavaFX application class must extend javafx.application.Application how to correct that?Please help
Hi Mukesh, I have faced web table questions in interviews like for a given time period print all US presidents from the wiki page. en.wikipedia.org/wiki/List_of_presidents_of_the_United_States. But this table little complicated. Could not complete it on time. Could please suggest the best approach??
@@Mukeshotwani Firstly the table structure is complicated i’m not able to find perfect rows bcoz of it. Second part is i’ve to fetch a particular row from column where column conditions needs to be true . So there are different columns like title , price and date i’ve to verify this column data and then fetch it
How to create a dynamic xpath - If i type sachin it should highlight India , if i give jeff it should highlight USA . please tell how to write such xpath
try something like this use parent and sibling both@@ManishaSG //table[@id='tablepress-1']//tr//td[contains(text(),'chrome')]//parent::tr/following-sibling::tr/td[4]
Sir in my table the columns content keep change for example new jobs or training will show in the table. I cant do expected vs actual title cuz i don't know what is expected as it keep changing. How will i verify that ?? Please answer.. this is urgent.
what if no. of rows are 1000? meaning we can see 50 rows at one time and we have to scroll again to see next 50 rows and so on... in that case if i need to scroll everytime and store in a hashmap, what should be approch? @mukesh
@Mukesh, //td[text()='Selenium'] This is not working for me. But, Below one works. //td[contains (text(),'Selenium')] What is the difference between above two? Please help.... Not getting where I am getting wrong...
First one exactly looks for text ‘Selenium’ .. even if the attribute contains ‘Selenium-x’ it’ll not work .. Whereas contains looks for contains with the keyword.🎉
This video is much better than naveen automation cos you covered many scenarios like scrapping all data, clicking from list or clicking directly using reversed customized XPath. Keep it up. Can you pls create video how we can compare two workbooks? Or how can we take webtable data in excel?
You can write the table date using list or map.
Super Video Boss... Thank you! My search for how to handle Dynamic Web Table in selenium has literally ended with this video
I was awesome . I thank you lot Mukesh, because of you and Naveen I m able to learn and get good opportunities.
Thank you
Thanks Biplov, I am glad our content is helping you. Keep Learning.
It has covered most of the needed xpaths, Thanks for your generosity and knowledge sharing.
So nice of you Thanks Umesh
very well explanation. Thank you so much for the video. It helps to understand and remember the concepts easily.
Thank you Sathya :)
Thanks Mukesh, Same kind on problem i was struggling from last one week in my organisation and your logich has helped me. Thanks a lot
Thanks for this Mukesh 😊, a revamped version for this topic is much much needed and now its there👍👍
Thanks Sarang
your explanation makes big concepts also so simple plz continue and give hope for ppl like us to continue testing
Thank u Aneetha 😊
Dude you saved my life. Thank you.
Glad I could help
Thanks Mukesh Sir very easily u taught how to deal with xpath.
Thanks Sandep.
Thank you Mukesh... Explained very clean and in sorted.
Thanks Komal
Hey Mukesh. it was a good explanation in this video.
I'd like to know how you handle cases where you need to write a generic method, using some string, in order to make some operation on specific data in the table.
In the video, you show the use of specific elements...
Hi Sir,
Thanks a lot for the video... it is currently helping me during interview process as this topic is very important.
I just had one small query:
Below is the example where you have declared two lists one for getting the row elements and one for getting the data. cant we use only one list as { List rowdata=driver.findElements(By.xpath("//table[contains(@id,'cust')]//tr/td")) } instead of the below two lits
List rowli=driver.findElements(By.xpath("//table[contains(@id,'cust')]//tr"));
List rowdata=driver.findElements(By.xpath("//table[contains(@id,'cust')]//td"));
Yes Rohan you can use td if only table data to verify but many time some rows like heading wont be part of td.
Thanku for sharing 👍make some real time interview questions n answer ... Waiting for more videos.... Stay safe n healthy
Thanks PS
Awesome..Best explanation ever.i m clear now..
Awesome 👏🏻
Great stuff… Thank you ☺️
Thanks Saleem
This is quite simple example we need some real time examples. Thanks
Thank you Mukesh. Your videos are really helpful :)
Hi Mukesh, Is there a way to handle AG-Grid using serenity framework or any Java testing framework. If yes, could you please make one video on that or could you please let us know any documentation on that.
Noted, I will try to make video on this.
Best explained...Thanks
1.Thank u for helping me a lot but mukesh how can we compare those table values with excel data table that means assume in case if we have download xl button then xl will download
2.so we need to compare same table data with excel data can u pls help me about that or else can u pls make a single video pls mukesh atleast one video is enough
one of d best explanation
Thanks a ton Padmini
Thanks. Useful session.
Glad it was helpful! Suganthi
Very helpful video
Glad it was helpful! Juhi
hii mukesh it was very good explanation I have one doubt in one student table some students are failed some of them passed I want failed student Alldata like phone number, mail id Please explain this topic once thank u
Thanks Srikanth, I will try
Hi Mukesh,
I want to find the some text from 1st column and then I want to click on the link which is present on next column in same row.
What logic we can use here, can you please suggest.
Thanks for the covered important topic. But still you are using indexing in xpath then how it comes the under dynamic. In future if any row or column added in table those xpath will not work right?
Hi Vital, Please share some dynamic tables with me, I will try to add them in new video as well.
Sir, do you have any example where xpath is changing dynamically in scroll view when user scrolls up and down??
Hi Palak, try to use xpath with text or axes so if elements attribute is changing it wont effect the scripts.
Awesome explanation.
Hi Sir, how to get the location for any specific data? ex: I need to check in which row or column India is appearing in case if the txt is dynamic. plz help
This is heavy lines of code and more weight to the class file.. we can achieve it with simple one dynamic XPath if we are looking for one specific data validation or multiple..just a thought 😉.. thanks for the info
Thanks Ajay but one dynamic XPath will not cover all scenarios
Hi mukesh,
Please make a video for handling captcha verification and OTP in selenium with python
OTP not sure but captcha will be uploading soon
@@Mukeshotwani thank u
too good explanation
Thank you Kiran
Thanks a lot @Mukesh
I don't want to use following or preceding but based on some condition wants to select checkbox. How this can be done???
Hi Baji, conditions like what?
Hello sir please make new series on Automation testing along with project
Noted Naved will try
when I add @Test ,I get the error...Error: Main method is not static in class practise.SeleniumPractise, please define the main method as:
public static void main(String[] args)or a JavaFX application class must extend javafx.application.Application
how to correct that?Please help
Please use @Test or use main method. You can not use both.
@@Mukeshotwani Thank you for this excellent video explanation
@@illusion7223 welcome :)
Hi mukesh can u let me know how to click each check box and how to get know each box selected or not
How to handle dynamic table in selenium, if row & column, both are dynamic and also How to validate multiple blank value in same row
I want to click check box with selenium text but what if this "selenium" data is changing dynamically.
You can parameterised the xpath
What if we want to fetch the data of country company which belongs to only india what if such condition are there ?
Thank Your Sir!
You are welcome!
Hello Sir, can you share the website URL which you used for this scenario.
Here is the URL seleniumpractise.blogspot.com/2021/08/webtable-in-html.html
Thanks. Alot sir🙏
Hi Mukesh, I have faced web table questions in interviews like for a given time period print all US presidents from the wiki page. en.wikipedia.org/wiki/List_of_presidents_of_the_United_States. But this table little complicated. Could not complete it on time. Could please suggest the best approach??
Hi Anumantha, what issue you are facing while completing this task.
Awesome sir
Thank you 😍
I need help with the dynamic table. There are few conditions for columns need help can you connect with me and help??
Hi Prasad please tell me what conditions you want to write ?
@@Mukeshotwani Firstly the table structure is complicated i’m not able to find perfect rows bcoz of it. Second part is i’ve to fetch a particular row from column where column conditions needs to be true . So there are different columns like title , price and date i’ve to verify this column data and then fetch it
It’s hard to explain in brief out here would be helpful if you connect I can try to explain in much better way.
thank you soo much
Glad it helped.
How to create a dynamic xpath - If i type sachin it should highlight India , if i give jeff it should highlight USA . please tell how to write such xpath
Hello, did you get the answer for your question because i am trying to find answer to same question
try something like this use parent and sibling both@@ManishaSG
//table[@id='tablepress-1']//tr//td[contains(text(),'chrome')]//parent::tr/following-sibling::tr/td[4]
Sir in my table the columns content keep change for example new jobs or training will show in the table. I cant do expected vs actual title cuz i don't know what is expected as it keep changing. How will i verify that ?? Please answer.. this is urgent.
Thank you
best
Thank you
How to automate if table has no table tr td tag?
Hi Vaibhav, you can have div tag or span tag but you will be writing the same logic only xpath will change
Code needs to be more clean. Use steam and reduce boilerplate code.
Yes I was focusing more on the approach but yes agree with you that code can be optimized.
you should start from installation
I don't think this WebTable is Dynamic.
Please give me some links which I can use for videos
what if no. of rows are 1000? meaning we can see 50 rows at one time and we have to scroll again to see next 50 rows and so on... in that case if i need to scroll everytime and store in a hashmap, what should be approch? @mukesh
Hi i need u r help
@Mukesh,
//td[text()='Selenium']
This is not working for me.
But, Below one works.
//td[contains (text(),'Selenium')]
What is the difference between above two?
Please help....
Not getting where I am getting wrong...
First one exactly looks for text ‘Selenium’ ..
even if the attribute contains ‘Selenium-x’ it’ll not work ..
Whereas contains looks for contains with the keyword.🎉
Thank you
I am glad it helped 😊