onscroll event

onscroll event

Post by Zach » Fri, 18 Mar 2005 05:08:56

Is there any event similar to the onscroll event of the IHTMLWindow2
interface but that gets fired whenever the person clicks the mouse
button down or up on the scroll thumb? What I really want is to be
able to keep some sort of boolean flag that says whether or not the
user is in the middle of a scrolling action. An obvious example of
this is the entire duration starting when the user clicks the thumb
tab, up until the time when the user releases the mouse button to
finish dragging the tumb tab.

1. c# - listbox onScroll event

2. handling onscroll event of WebBrowser

Hi Group
I'm writing an Internet Explorer plugin. Everything works well, except
when I try to handle the onscroll event.
another possibility seems to exist with IHTMLElement2.onscroll using
the document body, but this does not solve the problem.

the following code snippet compiles but when executed it always throws
a System.NotImplementedException
this is the stack trace:
in mshtml.HTMLWindow2Class.IHTMLWindow2_set_onscroll(Object p)

this is the code:
//WebBrowser is a valid instance of SHDocVw.WebBrowserClass
this.WebBrowser.DocumentComplete += new

void webBrowser_DocumentComplete(object pDisp, ref object URL)
mshtml.IHTMLDocument2 document =
mshtml.IHTMLWindow2 window = document.parentWindow;

//window.onscroll =
// new mshtml.HTMLWindowEvents_onscrollEventHandler(
// this.webBrowserWindow_onscroll);
window.onscroll =
new mshtml.HTMLWindowEvents2_onscrollEventHandler(
catch (Exception ex)

private void webBrowserWindow_onscroll()
private void webBrowserWindow_onscroll(mshtml.IHTMLEventObj pEvtObj)

any idea on what I'm doing wrong?

3. Detecting if onscroll events working / supported in Firefox

4. handling onscroll event of WebBrowser (repost)

5. Help with Opera & onscroll event.

6. onscroll Event Not Firing in ASP.NET 2.0

7. c# - listBox onScroll event

8. IE 8 - JavaScript onscroll event

9. onscroll event in iframe in IE

10. HTMLWindowEvents2 onscroll event not getting fired

11. test for onscroll support

12. DBGrid Record Change OnScroll

13. Web Browser OnScroll

14. Body onscroll, scrollTop, scrollLeft not working with master pages ???

15. Sorry OnVScroll ( Not onScroll )