Scroll down page in IDE

3,270 views
Skip to first unread message

Byron

unread,
Jul 8, 2011, 4:04:59 PM7/8/11
to Selenium Users
is there a way to scroll down a page in the selenium IDE?

KenCK

unread,
Jul 8, 2011, 9:34:12 PM7/8/11
to Selenium Users
There are various ways to do this with RC but AFAIK it's not possible
in IDE.

Jayakumar C

unread,
Jul 9, 2011, 5:19:29 AM7/9/11
to seleniu...@googlegroups.com
@Byron,

If you are going to scroll down the page to an element, you could try the cmd -

focus  |  locator   

If you want to scroll down the page based on co-ordinates , you could use something like -

storeEval  |  selenium.browserbot.getCurrentWindow().scrollTo(100,800)


scrollTo(xpos, ypos)
xpos - The coordinate to scroll to, along the x-axis
ypos - The coordinate to scroll to, along the y-axis



On 9 July 2011 01:34, Byron <byron....@gmail.com> wrote:
is there a way to scroll down a page in the selenium IDE?

--
You received this message because you are subscribed to the Google Groups "Selenium Users" group.
To post to this group, send email to seleniu...@googlegroups.com.
To unsubscribe from this group, send email to selenium-user...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/selenium-users?hl=en.




--
Jayakumar

Jayakumar C

unread,
Sep 28, 2011, 6:04:43 AM9/28/11
to seleniu...@googlegroups.com
Have you passed the JS snippet to the getEval call ?

selenium.getEval("selenium.browserbot.getCurrentWindow().scrollTo(100,800);") ;

On 28 September 2011 14:25, Anand Sharma <anands...@gmail.com> wrote:
Hi Jaya ,

I am using Eclipse IDE + JUNIT 4+ selenium RC .
when i put the command
selenium.browserbot.getCurrentWindow().scrollTo(100,800);

It gives me error in my Java test case.
What i found is , in selenium package , there is no browserbot .

Please let me know the correct syntax so that the current window get
scrool dowm while test case is executing.

Thanks,
Anand


On Jul 9, 2:19 pm, Jayakumar C <jayakumaree...@gmail.com> wrote:
> @Byron,
>
> If you are going to scroll down the page to an element, you could try the
> cmd -
>
> focus  |  locator
>
> If you want to scroll down the page based on co-ordinates , you could use
> something like -
>
> storeEval  |  selenium.browserbot.getCurrentWindow().scrollTo(100,800)
>
> scrollTo(*xpos, ypos*)
> *xpos - *The coordinate to scroll to, along the x-axis
> *ypos* - The coordinate to scroll to, along the y-axis

>
> On 9 July 2011 01:34, Byron <byron.mora...@gmail.com> wrote:
>
> > is there a way to scroll down a page in the selenium IDE?
>
> > --
> > You received this message because you are subscribed to the Google Groups
> > "Selenium Users" group.
> > To post to this group, send email to seleniu...@googlegroups.com.
> > To unsubscribe from this group, send email to
> > selenium-user...@googlegroups.com.
> > For more options, visit this group at
> >http://groups.google.com/group/selenium-users?hl=en.
>
> --
> Jayakumar



--
Jayakumar

Anand Sharma

unread,
Sep 28, 2011, 6:10:57 AM9/28/11
to seleniu...@googlegroups.com
No ,
i  have test case in java. In that java class, i have written something like this:

selenium.browserbot.getCurrentWindow().scrollTo(100,800);

selenium.type("name=qty", qty);
selenium.click("name=submit");

so that it will scroll the window at the end , and i can see the submit button.

Thanks,
Anand
thanks,
Anand sharma

Jayakumar C

unread,
Sep 28, 2011, 6:43:31 AM9/28/11
to seleniu...@googlegroups.com
Try this to scroll down to the position x=100, y=800.

selenium.getEval("selenium.browserbot.getCurrentWindow().scrollTo(100,800);") ;

and try this to scroll down to the submit element.

selenium.focus("name=submit");
Reply all
Reply to author
Forward
0 new messages