XLM Rears Its Ugly Head - -And Crashes Excel
Caution: This will crash Excel. So if you try it, make sure you don't have any unsaved work.
Try this useless and strange tidbit:
Enter this simple procedure in the code module for ThisWorkbook:
Private Sub Workbook_BeforePrint(Cancel As Boolean) Stop End Sub
- Put something in the workbook (anything, so it will print)
- Click the Print Preview button.
- At the breakpoint, press F5. All is OK.
- Now try it again, but this time when you get to the Stop statement, keep pressing the F8 key, even after you return from the Print Preview. Somehow, you will be thrown into some ancient XLM code which doesn't work (see the figure below) Anything you click on just turns bold! Time for the Three-Finger Salute.
Excel is a complex program, and has been around for a long time. Consequently, it has many obscure nooks and crannies to discover. Some of them are described here.
Keep in mind that some versions of Excel are odder than others. In other words, the things described here may not apply to all versions of Excel.
All Odd Stuff
Browse Oddities by Category
Seen Something Odd?
If you've discovered something weird about Excel, let me know.