Thanks so much for persisting. As to the %$@&^%!! 1004, both test and test2 give the historically inept message
Run-time error '1004':
Application-defined or object-defined error
Maybe Excel version is in play here. XL03 gives 1004s when run from subs, but not when the same thing is done in Immediate (Debug) window. So evidently a 2003 bug. Funny, this is the only thing I've seen in 10 heavy usage years that actually got fixed in 2007+ (to accompany the interface annihilation).
On XL07: like with Andy's, on the original O.P. example (A1:D2) both test and test2 reproduce control-shift-left arrow.
But on my above A1:C2 scenario, both test and test2 leave everything selected (a1:c2); Andy's leaves a1:b2 selected, and ctrl-shift-left leaves a1:a2 selected.
Were you using 03 today (your profile says 03)?
To save hitting page-up if you're just tuning in,
A1:D2 original scenario: zero (or anything) in B1, B2 and D2
A1:C2 second scenario: zero (or anything) in all cells but A2
Bookmarks