---------- Forwarded message ---------- From: <[EMAIL PROTECTED]> Date: Tue, Oct 21, 2008 at 4:28 PM Subject: Re: RichTextBox Scroll Position To: [EMAIL PROTECTED]
Hi Ivan, Thanks so much for the hint. It works like a charm! Kind Regards, Al Ivan N. Zlatev wrote: > > On Mon, Oct 20, 2008 at 5:00 PM, Alisdair Little > <[EMAIL PROTECTED]> wrote: >> >> Hi Guys, >> >> Any idea how to get the vertical scroll position for a RichTextBox? >> >> I have tried; >> [DllImport("user32")] >> public static extern bool GetScrollInfo(IntPtr hwnd, int fnBar, >> ref >> SCROLLINFO lpsi); >> [DllImport("user32")] >> public static extern int GetScrollPos(IntPtr hwnd, int nBar); >> [DllImport("user32")] >> public static extern int SendMessage(HWND hwnd, int wMsg, int >> wParam, IntPtr lParam); >> >> All these calls work under Visual Studio/windows but not under mono. >> My Environment: Windows XP, Visual Studio 2005 and Mono 2.0. >> > > What about richTextBox.GetPositionFromCharIndex > (richTextBox.GetFirstCharIndexFromLine (0)).Y ? > > -- > Kind Regards, > Ivan N. Zlatev > _______________________________________________ > Mono-devel-list mailing list > Mono-devel-list@lists.ximian.com > http://lists.ximian.com/mailman/listinfo/mono-devel-list > > Quoted from: http://www.nabble.com/RichTextBox-Scroll-Position-tp20073031p20092389.html -- Kind Regards, Ivan N. Zlatev _______________________________________________ Mono-devel-list mailing list Mono-devel-list@lists.ximian.com http://lists.ximian.com/mailman/listinfo/mono-devel-list