How Can I Click the Mouse?

Blake

Registered User.
Local time
Today, 14:55
Joined
Aug 28, 2002
Messages
21
I have a situation in which I want my application to click the left mouse button, once. The purpose is to clear the black highlighting in a control which has the focus, due to a FindRecord action. I'm aware of the SendKeys action, which lets one send various keycode combinations, and I'm aware of the various events that let me tell if the user has clicked the mouse, but I don't see how to click the mouse (perhaps because that's not recommended?)

Regards, Blake
 
One way to unhighlight text inside a control is to set the SelLength to Zero.

txtBox1.SetFocus
txtBox1.SelLength = 0

If you don't know which control you're going to be in then you can use:

Screen.ActiveControl.SelLength = 0

Peace
 
Last edited:
Thanks hugely Drevlin. That did the trick nicely.

Regards, Blake
 

Users who are viewing this thread

Back
Top Bottom