Aditya Anand
Aditya Anand

Reputation: 201

How to go directly on a certain page no.?

I am using python3 selenium. They are using this to navigate to another page "__doPostBack('ctl00$ContentPlaceHolder3$gvSearchDentistlist','Page$5')".

Here is the link of page.I wanted to go on page 5 directly.

https://dciindia.gov.in/DentistsSearch.aspx?Reg_Type=D&RegUnder=0&IDRId=&IDRName=&CourseId=0&RegDate=0&CouncilId=

Upvotes: 0

Views: 31

Answers (1)

PDHide
PDHide

Reputation: 19979

driver.get('https://dciindia.gov.in/DentistsSearch.aspx?Reg_Type=D&RegUnder=0&IDRId=&IDRName=&CourseId=0&RegDate=0&CouncilId=')

javascript= "__doPostBack('ctl00$ContentPlaceHolder3$gvSearchDentistlist', 'Page$5')"

driver.execute_script(javascript)
input()

if you inspect that page hyper links you can see it use javascript , just call that function from script as above :

enter image description here

if you want to call page 11 change 'Page$5' to 'Page$11'

Upvotes: 1

Related Questions