Something else you should note is the changeflag in the code
when working with userform and spreadsheet it is so easy to get into a loop.
Sheet change macro starts and modifies the sheet, so that starts of the sheets change macro which modifies the sheet, so that starts of the sheets change macro which modifies the sheet, so that starts of the sheets change macro which modifies the sheet, so that starts of the sheets change macro which modifies the sheet
ad infinitum.
So if the flag is one, you skip the part of the sheet that modifies the sheet thus avoiding a loop. But when you finish the flag must be set to 0 otherwise the macro will never work.
Guess What? That is why your macro never works after you crashed it. if you had run the line
Then you wouldd not have needed to close the macro. and reopen it.
Bookmarks