Sign in to follow this  
Followers 0
Andrew Peacock

Scrolling a rich text box

3 posts in this topic

Hi all,

I'm using a rich text edit box as defined here:

$editRichText = ObjCreate("RICHTEXT.RichtextCtrl.1")

I'm trying to get the text to scroll so that the highlighted text is roughly in the middle of the box. Has anyone done this before and can point a way?

Regards,

Andy

Share this post


Link to post
Share on other sites



#2 ·  Posted (edited)

Hallo Andrew

something like this

With $ComponetPool
   .SelStart = 0
   DllCall("user32.dll","long","SendMessage","hwnd",.Hwnd,"int",$EM_LINESCROLL,"int",0,"int",$iLines)
EndWith

This will scroll the component int $ilines from top

This post should actually have been listed in ActiveX/Com support...

kjactive :)

Edited by kjactive

Share this post


Link to post
Share on other sites

Thanks kjactive, that should help. I must confess, I'd not actually noticed the Activex/COM forum before :-)

Regards,

Andy

Hallo Andrew

something like this

With $ComponetPool
   .SelStart = 0
   DllCall("user32.dll","long","SendMessage","hwnd",.Hwnd,"int",$EM_LINESCROLL,"int",0,"int",$iLines)
EndWith

This will scroll the component int $ilines from top

This post should actually have been listed in ActiveX/Com support...

kjactive :)

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0