Page 1 of 1

Preset scrolling of web browser?

Posted: 13 Jan 2014, 02:10
by shermanpat
Looking to preset a scroll down a webpage.
Which doesn't seem to be supported when i read this in the manual "There is currently no other way to scroll the page than to use the scroll bars inside the browser."
But i am able to use the scroll wheel on the mouse or the keyboard up and down buttons.

Wondering if there is a way to emulate a mouse scroll wheel move in a animation node?
Can you also emulate a mouse click on a specific point screen as well?
Is there a way to define how far the keyboard Up and Down arrows scroll?(Could use that if the distance moved was smaller or more fluid)

Or if anyone has a suggestion for work around I would love to hear them.

Thanks!

Re: Preset scrolling of web browser?

Posted: 13 Jan 2014, 21:22
by TobiTobsen
What about a quick hack in c# and emulate key events? So you could insert Events like Mouse wheel down and up...
Not sure if this will work...

Re: Preset scrolling of web browser?

Posted: 13 Jan 2014, 21:51
by TobiTobsen
Japp it's working, find attached a quick test...

Not sure if there is a way to define sth like the scroll distance... otherwise it does really not look very smooth.

Hope it helps?

Re: Preset scrolling of web browser?

Posted: 14 Jan 2014, 02:38
by shermanpat
Thank you for the reply and C# example, I really need to get working on my code skills more. That looks like a nice way to emulate the button presses.

I found a work around for the scroll using some timers triggering Invoke of a direct key input for UP/Down. It presses Down every 0.2S for 6S, then switches to Invoke of Up every 0.2S for 6S to get back to the top of the page. Works great but still goes in steps rather than a smooth scroll, but client says it looks ok so one to the next thing.


Still word love to see a way to emulate a TUIO/Touch/Mouse click event. Mainly so that you could do a scripted look around a live client web page. Maybe I could just figure out the URL of the button clicked on the web pages?

Thanks again, it just help to be able to get the thoughts out and hear what you Pros think. Still lots of learning to go!

Re: Preset scrolling of web browser?

Posted: 14 Jan 2014, 03:05
by shermanpat
really don't know HTML and JS stuff but here is code for one of the buttons i am trying to click.

<button class="SummaryReportNavBar-nextButton button theme-button" data-ember-action="25">Next</button>