@msdn=http://search.microsoft.com/search/results.aspx?qu=$$$ @pinvoke=http://pinvoke.net/$$$.htm Summary: The ScrollWindowEx API !!!!C# Signature: [DllImport("user32.dll")] static extern int ScrollWindowEx(IntPtr hWnd, int dx, int dy, IntPtr prcScroll, IntPtr prcClip, IntPtr hrgnUpdate, IntPtr prcUpdate, uint flags); !!!!User-Defined Types: None. !!!!Flags: /// <summary> /// Scroll children within *lprcScroll. /// </summary> public const uint SW_SCROLLCHILDREN = 0x0001; /// <summary> /// Invalidate after scrolling. /// </summary> public const uint SW_INVALIDATE = 0x0002; /// <summary> /// If SW_INVALIDATE, don't send WM_ERASEBACKGROUND. /// </summary> public const uint SW_ERASE = 0x0004; /// <summary> /// Use smooth scrolling. /// </summary> public const uint SW_SMOOTHSCROLL = 0x0010; !!!!Notes: None. !!!!Tips & Tricks: Please add some! !!!!Sample Code: [DllImport( "user32.dll" )] static extern int ScrollWindowEx( IntPtr hWnd, int dx, int dy, IntPtr prcScroll, IntPtr prcClip, IntPtr hrgnUpdate, IntPtr prcUpdate, uint flags ); unsafe private void hScrollBar1_Scroll( object sender, ScrollEventArgs e ) { int ScrollDelta; RECT ScrollRect = new RECT(); ScrollDelta = FPosition - e.NewValue; // FPosition is the previous scrollbar position FPosition = e.NewValue; if ( ScrollDelta != 0 ) { ScrollRect.Left = 100; ScrollRect.Top = 50; ScrollRect.Right = this.Width - SystemInformation.VerticalScrollBarWidth; ScrollRect.Bottom = this.Height - 50; IntPtr RectPointer = new IntPtr( &ScrollRect ); ScrollWindowEx( this.Handle, ScrollDelta, 0, RectPointer, RectPointer, (IntPtr)null, (IntPtr)0, 2 ); } } !!!!Alternative Managed API: Do you know one? Please contribute it! Documentation: ScrollWindowEx@msdn on MSDN
Edit user32.scrollwind...
You do not have permission to change this page. If you feel this is in error, please send feedback with the contact link on the main page.