>>There is one thing which can gray out 'close' button: it's some form property pointing to existing object. All these properties should be set to NULL in Form.Destroy event.
>
>Hi Ed,
>
>I've seen this sort of thing an error occurs, but not otherwise. Of course, the debugger was open and the program had been suspended. I may be being a bit "thick" here, but could you give me an example of what you mean?
Let say, some custom form property holds object reference, e.g. form contains pageframe and each page activate event fires:
Thisform.ActivePageObject=This && surely, it's just an example, it can be buttons, textboxes etc , even exteranl objects
Now, if you will not issue This.ActivePageObject=.NULL. in Form.Destroy event, you cannot release the form and close button is grayed out.
Edward Pikman
Independent Consultant