OpenDCL Forums

OpenDCL => Runtime/AutoLISP => Topic started by: architrave on August 29, 2008, 02:40:48 PM

Title: Event invoke from a tree control needs two clicks?
Post by: architrave on August 29, 2008, 02:40:48 PM
I am using a dockable form with a tree control. I want to get one point from AutoCAD when I rigthclick on one item of the tree.

Everything works correct excep that I have to click twice (one for getting the focus on AutoCAD window and the second to select the point).

However if I try to do the same operation but using a button control there is no need of two clicks.

Can I avoid the double click when using tree controls.

I am using th 4.1.2.2 version

Thank you very much
Title: Re: Event invoke from a tree control needs two clicks?
Post by: BazzaCAD on August 29, 2008, 02:53:00 PM
Hello architrave & welcome to the team.
Try adding (dcl_SetCmdBarFocus) to your RightClick Event.
So Acad will take focus before you pick inside the window.
Title: Re: Event invoke from a tree control needs two clicks?
Post by: BazzaCAD on August 29, 2008, 02:58:48 PM
Or you can uncheck the "Keep Focus" property on your dockable form.
Title: Re: Event invoke from a tree control needs two clicks?
Post by: architrave on August 29, 2008, 03:06:41 PM
I had the EventInvoke property set to 1-Allow (Command ... ) and it did not worked.

However, (dcl_SetCmdBarFocus)  works perfectly.

Thank you very much.

Title: Re: Event invoke from a tree control needs two clicks?
Post by: owenwengerd on August 29, 2008, 08:06:30 PM
Quote from: BazzaCAD on August 29, 2008, 02:58:48 PM
Or you can uncheck the "Keep Focus" property on your dockable form.

OpenDCL 4.1 doesn't have that property .