Question : Type mismatch error when setting row height or column width

I have a spreadsheet that is fairly large and within it must format some rows and columns (among many, many other things).  This is 99% complete and while I was in the midst of testing, it started giving me type mismatch errors when the macro was attempting to manipulate rows and columns.  The code for this is quite simple.

What's very confusing here is that I've run this countless times and it worked perfectly, so this error started occurring very randomly.  I've run code cleaner, detect & repair, with no luck.  I even pulled up an older version of this workbook, which runs the exact same code to manipulate columns and rows, and it worked fine.  Yet when I now run the most recent version, I get the type mismatch error every time that I run any code that modifies rows or columns (I now can't even delete them without receiving this error).  Any help is greatly appreciated.  Below are a couple of examples of the code in question.
Code Snippet:
1:
2:
3:
4:
5:
6:
7:
'set row height
With Sheets("TLM").Rows("4:5")
     .RowHeight = 36
End With
 
'delete rows
Sheets("TLM").Rows("1:8").Delete

Answer : Type mismatch error when setting row height or column width

Alright, well I feel a little stupid for not figuring this out earlier, but here was my problem.  I had a macro that selected a chart and set a property for that chart, after which I then moved on to setting some column widths, which led to the type mismatch error.  Apparently I need to move the focus from the chart before I could start setting worksheet properties.  I wasn't aware that this was an issue, but had I followed a little more analytical process in troubleshooting this, I could have figured it out a little more quickly.  Kevin, thanks for your help - have a great New Year!
Random Solutions  
 
programming4us programming4us