![]() ![]() This is what the user wanted to do anyway. This form has code that repurposes the red X, turning a click on that button to a click on the form’s Close button. ![]() This is not good, because the calling code will be unable to communicate with the form. The default behavior of the red X in the top right corner is to unload the form, that is, clear it from memory. This way, the calling code can interact with the form after it has been dismissed. This userform has code behind the OK and Cancel buttons to hide the form, which keeps it resident in memory. It’s your job as programmer to make the escape route work both for the user and for the program. ![]() Leave the button in place as an obvious way to escape the running procedure. My answer is that you shouldn’t hide the red button, since the user knows what it does, or at least what it’s supposed to do. A frequently asked question is “How do I hide the red X close button on the corner of a VBA user form?” ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |