I'm currently using the attached code to extend columns. I would like use to it only for specific columns and keep and minimum column width. Any help would be appreciated.
ThanksHTML Code:
E.
I'm currently using the attached code to extend columns. I would like use to it only for specific columns and keep and minimum column width. Any help would be appreciated.
ThanksHTML Code:
E.
Last edited by enhydra; 09-16-2017 at 12:23 AM.
How are the specific columns arrived at?
- predetermine (eg columns A,C, H auto fit, others minimum width)?
OR
- user asked to decide when values change?
If you favour the former
- which columns are to auto-fit?
- should all the other columns be left unchanged?
Click *Add Reputation to thank those who helped you. Ask if anything is not clear
Columns are preset and locked except for columns R through AB. I want columns R through AB to auto extend but not drop below a minimum of 7 width. Or at least that's what i'm trying for.
Thanks
E.
These 2 lines should be all you need in your change macro
The active column should stretch if latest data is wider than previous widest data in that column.Please Login or Register to view this content.
AutoFit tends not to work if the width of the column has already been changed from default to another specified width
- so how about fixing the headers with some spaces to ensure required width does not fall below 7 or create a dummy row (row1?) in order to achieve this
Merged cells cause problems for AutoFit - remove any merged cells
Thanks Kev, that's works great.
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks