How To Handle Dynamic Web Table In Selenium WebDriver | Capture Dynamic WebTable In Selenium
ฝัง
- เผยแพร่เมื่อ 15 ส.ค. 2021
- In this video, I will discuss how to handle dynamic web table in Selenium webdriver and how to verify the table data as well.
XPath In Selenium Part 1 and Part 2
• Dynamic XPath in Selen...
• How to create Dynamic ...
TestNG Tutorials
• Testng Tutorial for Be...
Assert in TestNG
• How to use Assertion i...
All Playlist
/ mukeshotwani
Connect with us:
Linkedin- / mukesh-otwani-93631b99
Instagram- / mukeshotwani
Facebook Group- / 256655817858291
Facebook Page- / seleniumwebdrivermukesh
Twitter- / mukeshotwani
Blog- learn-automation.com - วิทยาศาสตร์และเทคโนโลยี
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.
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
Super Video Boss... Thank you! My search for how to handle Dynamic Web Table in selenium has literally ended with this video
It has covered most of the needed xpaths, Thanks for your generosity and knowledge sharing.
So nice of you Thanks Umesh
Awesome..Best explanation ever.i m clear now..
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.
Dude you saved my life. Thank you.
Glad I could help
Thank you Mukesh... Explained very clean and in sorted.
Thanks Komal
Best explained...Thanks
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.
Thanks Mukesh Sir very easily u taught how to deal with xpath.
Thanks Sandep.
Thank you Mukesh. Your videos are really helpful :)
Thanks for this Mukesh 😊, a revamped version for this topic is much much needed and now its there👍👍
Thanks Sarang
Awesome explanation.
your explanation makes big concepts also so simple plz continue and give hope for ppl like us to continue testing
Thank u Aneetha 😊
Awesome 👏🏻
Great stuff… Thank you ☺️
Thanks Saleem
Thanks a lot @Mukesh
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
Thanks. Useful session.
Glad it was helpful! Suganthi
This is quite simple example we need some real time examples. Thanks
What if we want to fetch the data of country company which belongs to only india what if such condition are there ?
Thank you
one of d best explanation
Thanks a ton Padmini
Thank Your Sir!
You are welcome!
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 mukesh can u let me know how to click each check box and how to get know each box selected or not
thank you soo much
Glad it helped.
Thanku for sharing 👍make some real time interview questions n answer ... Waiting for more videos.... Stay safe n healthy
Thanks PS
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.
too good explanation
Thank you Kiran
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.
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?
Awesome sir
Thank you 😍
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.
I want to click check box with selenium text but what if this "selenium" data is changing dynamically.
You can parameterised the xpath
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
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.
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.
best
Thank you
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.
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
How to handle dynamic table in selenium, if row & column, both are dynamic and also How to validate multiple blank value in same row
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🙏
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
Hello sir please make new series on Automation testing along with project
Noted Naved will try
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]
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
you should start from installation
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.
I don't think this WebTable is Dynamic.
Please give me some links which I can use for videos
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.
@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.🎉
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
Thank you
I am glad it helped 😊