VBA Dialog Boxes Losing Focus

VBA Dialog Boxes Losing Focus

Anonymous
Not applicable
1,268 Views
1 Reply
Message 1 of 2

VBA Dialog Boxes Losing Focus

Anonymous
Not applicable
Hi

I'm having a silly problem with my first VBA code in a LONG time. Whatever dialog box I attempt to open using code, be it a form or an InputBox, I can't enter text. It seems that the box is losing focus immediately. If I hammer on the left mouse key and the keyboard I can sometimes get text to go into the box, but that's obviously not the controlled text I want.

I'm using Vista x64 with two monitors. I've tried moving all the windows to one screen with no difference in effect.

Any help would be greatly appreciated.
0 Likes
1,269 Views
1 Reply
Reply (1)
Message 2 of 2

Anonymous
Not applicable
Im not using Vista, and Im on 32 bit, so I can only offer a perspective, and maybe a couple of questions:

1) Are you having trouble with youir OWN forms?
2) if so, are your forms being loaded "Modally" ? (The "ShowModal" propert of the form)

if so, check to see if your version of acad has the "AcFocus" control avalable. With the "ToolBox" open, right-click on it, select "Additional Controls", and scroll down to see if there is an "AcFocus" control.

There is a known problem in earlier versions that sounds -similar- to what you are describing, and this control is the fix for it. (or, just having your forms "ShowModal" property set to TRUE)
0 Likes