Results 1 to 5 of 5

Thread: Autofit Row height is not working in Microsoft Excel 2007

  1. #1
    Join Date
    Nov 2011
    Posts
    56

    Autofit Row height is not working in Microsoft Excel 2007

    I have several cells that are aligned "Top" with wrap text turned on that run past the border of the cell. The Format/AutoFit Row Height command does not fix the issue, nor does selecting all and clicking on the bottom row border. I'm having to fix them all by hand. What am I doing wrong? They are only one or two sentences long, so shouldn't be too much data. Thanks.

  2. #2
    Join Date
    Aug 2011
    Posts
    566

    Re: Autofit Row height is not working in Microsoft Excel 2007

    Are the cells "merged". Merged cells with wrap text won't Autofit. You need VBA event code to get the autofit.

  3. #3
    Join Date
    Nov 2011
    Posts
    56

    Re: Autofit Row height is not working in Microsoft Excel 2007

    My cells weren't merged, but the header cells over them in Row 1 were. I deleted the merged cells, saved all as a new document and tried again. Still didn't work. I then selected all and unchecked the "Wrap Text" box so it's back on the normal wrap setting. That put all the rows at one-line height. I then selected all and did Format/AutoFit Row Height. Still not working. I'm not a developer, but tried that link you sent. I tried the code using the VB window for each sheet. Nothing happened, so I tried the Format/AutoFit Row Height command again after pasting the VB code, but nothing seemed different. I don't really know how to use VB though, so I'm sure it's user error. It doesn't seem to make sense that as a layman I would need to know how to use VB code just to make the rows AutoFit....I think I am missing something.

  4. #4
    Join Date
    Jul 2011
    Posts
    623

    Re: Autofit Row height is not working in Microsoft Excel 2007

    With Target If .MergeCells And .WrapText Then. If you have no merged cells, the code will do nothing so might as well delete the code from your sheet. In order for Autofit to work properly, the cells must be set to Wrap Text. Select all and set to Wrap Text. Select all rows and set to Autofit.

  5. #5
    Join Date
    Jul 2011
    Posts
    634

    Re: Autofit Row height is not working in Microsoft Excel 2007

    Still doesn't work. I think my workbook is broken. I'll probably be bettter off starting from scratch with a new one. Those features all work properly when I open a new workbook and play with the cells, so there must be something wrong with my data. Ugh.

Similar Threads

  1. Rightclick is not working in Microsoft Excel 2007
    By (Cowherd) in forum Windows Software
    Replies: 5
    Last Post: 22-03-2012, 06:40 PM
  2. How to open UTF-8 in Microsoft Excel 2007
    By Kaesav in forum MS Office Support
    Replies: 2
    Last Post: 10-02-2012, 05:19 PM
  3. F2 key is not working in Microsoft Excel 2007
    By ELETTRA| in forum MS Office Support
    Replies: 2
    Last Post: 03-02-2012, 05:59 PM
  4. How to know height of row in Excel?
    By Dipanwita in forum Windows Software
    Replies: 2
    Last Post: 04-01-2012, 07:19 PM
  5. Benefits of using Microsoft Excel 2007
    By XDRoX in forum Tips & Tweaks
    Replies: 1
    Last Post: 06-04-2009, 05:24 PM

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Page generated in 1,642,625,198.20253 seconds with 17 queries