Hi all.
I have a form with a subform. The OnExit event for the subform control tests for valid input from the user. If it's not valid, I want to disable the navigation and Close buttons (the X), with a Msg box instructing the user how to correct his error. I hid the navigation buttons by setting the property Me.NavigationButtons = False. This works fine, and once the user corrects the error, I reset it to true.
I tried to do the same with the CloseButton property:
Me.CloseButton = False. However, I got an error message saying "Run time error '2448'. You can't assign a value to this object"
Why do I get this error? Any assistance would be greatly appreciated.
Thanks
Steve
I have a form with a subform. The OnExit event for the subform control tests for valid input from the user. If it's not valid, I want to disable the navigation and Close buttons (the X), with a Msg box instructing the user how to correct his error. I hid the navigation buttons by setting the property Me.NavigationButtons = False. This works fine, and once the user corrects the error, I reset it to true.
I tried to do the same with the CloseButton property:
Me.CloseButton = False. However, I got an error message saying "Run time error '2448'. You can't assign a value to this object"
Why do I get this error? Any assistance would be greatly appreciated.
Thanks
Steve