For Programmers: Free Programming Magazines  


Home > Archive > Clarion > December 2004 > Re: How to highlight all the Text for a Text field when getting focu









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author Re: How to highlight all the Text for a Text field when getting focu
JMumf

2004-12-18, 12:46 pm

Jim,

Thank, but I've tried your solution. It work from a SingleThreaded
Menu. But fails from a Frame.
I went back and tested it again just in case. I've got a simple App
with 2 menus (SingleThreaded and Frame) and one window procedure. I
switch from Single to Threaded Frame to verify. When testing I'm
putting the code in ThisWindow.TakeSelected for the Selected Field.
Currently I'm only testing with ABC.

>From a Frame with your method the highlighting always stops at the

location of the cursor when the mouse is used.

My API method above works, but it moves the cursor.
Which I don't like. Other than that it seems to work fine.

If you have another idea let me know and I will give it a try. I would
prefer your solution because then I would not need to move the cursor.

Do you know how to calculate the actual length of the text. That would
improve what I'm doing.

Thanks,

Jim Mumford

Sponsored Links







Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive

Copyright 2008 codecomments.com