Re: Auto-select text in editbox

Author: Paul McNett

Posted: 2001-10-09 at 15:47:48

On Tuesday 09 October 2001 01:42 pm, Dan Covill wrote:

> As I recall, the 'K' works if you tab/enter into the box, but not if you

> click on it. The cure (I believe) is to put the following into the

> GotFocus() method:

> this.SetFocus()

I find that calling SetFocus() is pretty intensive performance-wise. There

is always a substantial delay after calling it. I avoid it like anthrax.

IMO the KEYBOARD solution would be much faster.

I used to avoid doing the KEYBOARD thing because I thought that it was

non-OOP, but I've found that most things will happen so much faster in VFP

using KEYBOARD versus the obvious OOP way.

--

Paul McNett

Hollister, CA USA

©2001 Paul McNett