LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 177
Default AutoFit Madness

I'm going nuts trying to figure out what's wrong with this bit of code:

Range(r1.Offset(, bias2), r1.Offset(0, bias1 +
bias2)).EntireColumn.AutoFit

When executed no autofitting occurs. No error either. If I look at the
individual ranges they have addresses like $G$11 and $R$11 respectively.


If I change the code to:

Range(r1.Offset(, bias2).Address, r1.Offset(0, bias1 +
bias2).Address).EntireColumn.AutoFit

then it works as expected but I don't typically turn my ranges into
addresses and they've always worked OK. So why not here?


I also tried:

r1.Parent.Range(r1.Offset(, bias2), r1.Offset(0, bias1 +
bias2)).EntireColumn.AutoFit

but that didn't change anything (i.e., it still failed to autofit).


Anybody got any idea what's going on?

TIA,

josh

p.s. I'm doing this testing under XL97


 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Sorting Madness JSnow Excel Discussion (Misc queries) 5 February 11th 09 05:52 PM
Formula Madness IoHeFy Excel Discussion (Misc queries) 2 January 4th 07 01:16 PM
Multimodal Madness Rothman Excel Worksheet Functions 0 March 16th 06 12:56 AM
VBA Names madness Jag Man Excel Programming 2 December 30th 03 12:57 AM
More Macro Madness Josh in Tampa Excel Programming 5 October 24th 03 11:14 PM


All times are GMT +1. The time now is 07:46 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"