Date: prev next · Thread: first prev next last
2015 Archives by date, by thread · List index

If this is not the best list for this question, please let me know of a more
appropriate one. 

I'm using a few simple controls on a Calc sheet, and Libre Basic to
manipulate them. So far I have had success, pulling test from a text box,
pulling text from cells on the sheet, changing the list of strings shown in
a list box and handling button clicks. 

Now I would like to improve the UI (from my point of view), such that once
the button click handler has done its job, the code sets the focus back to
the initial text box I was typing in and preselects all text, so that I can
immediately start typing the next name to work with. 

I've Googled the heck out of it with various terms, looked through the SDK
docs and I'm using XRAY to see the properties and methods of the controls,
which is how I got this far... but none of them are helping now. I see no
property or method relating to selection or focus. 

I *do* see a Start and End property, which are text ranges, but I don't
quite understand what they represent; I would have expected just one range
representing the first and last selected character positions - if they are
even related to selection. 

I read somewhere that there's a SetFocus() method but that it is on the
*view* aspect of the edit box. No problem... but I can't find a way to
access the view portion either :(  

There are lots of examples out there - many are even for forms - but none
seem to deal with focus or selection. 

Can anyone point me towards some information on how to access such things? I
can't even get the selected text if I needed to. 


View this message in context:
Sent from the Users mailing list archive at

To unsubscribe e-mail to:
Posting guidelines + more:
List archive:
All messages sent to this list will be publicly archived and cannot be deleted


Privacy Policy | Impressum (Legal Info) | Copyright information: Unless otherwise specified, all text and images on this website are licensed under the Creative Commons Attribution-Share Alike 3.0 License. This does not include the source code of LibreOffice, which is licensed under the Mozilla Public License (MPLv2). "LibreOffice" and "The Document Foundation" are registered trademarks of their corresponding registered owners or are in actual use as trademarks in one or more countries. Their respective logos and icons are also subject to international copyright laws. Use thereof is explained in our trademark policy.