EditorGadget scroll to bottom

Just starting out? Need help? Post your questions and find answers here.
sc4pb
User
User
Posts: 32
Joined: Tue Mar 07, 2023 5:33 pm

EditorGadget scroll to bottom

Post by sc4pb »

I've been searching, sometimes simple answers hardest to find... After I've added text to an editorgadget, either through multiple calls to AddGadgetItem, or with one call to SetGadgetText (where the string contains multple CRLFs) ...how do I get the editorgadget to automatically scroll to the bottom so the user can see the most recently added content?

Thanks!
User avatar
ChrisR
Addict
Addict
Posts: 1469
Joined: Sun Jan 08, 2017 10:27 pm
Location: France

Re: EditorGadget scroll to bottom

Post by ChrisR »

Windows only:

Code: Select all

SendMessage_(GadgetID(0),#EM_SETSEL,0,0)
SendMessage_(GadgetID(0),#EM_LINESCROLL,0,CountGadgetItems(0)-1)
Post Reply