I have a procedure that sets the Enabled property of a form to False when starting and True when finished, to prevent the user from clicking other buttons. However, it seems the Enabled property isn't being set to True when the procedure ends.
I can duplicate the problem by creating a simple form with one checkbox. The code for clicking the checkbox is:
Private Sub chkToggle_Click()
Me.Enabled = False
Me.Enabled = True
The form ends up being disabled (not clickable) after the first click. The same code in AutoCAD 2000 VBA works with no problems.
If I set a breakpoint at the Me.Enabled = True line, and then press F8 once when it gets there, the form ends up being enabled. However, adding a timed For/Next loop and DoEvents doesn't seem to help, however.
Does anyone have any suggestions on how to get it to work? I'm using IntelliCAD 22.214.171.124.
The VBA forum deals with IntelliCAD 2000 VBA (Visual Basic for Applications) issues.
Moderator: CMS Inc
1 post • Page 1 of 1