+ Reply to Thread
Results 1 to 3 of 3

Blank Line when using Center Across Selection

  1. #1
    Registered User
    Join Date
    01-09-2012
    Location
    Stephens City, VA
    MS-Off Ver
    Excel 2007
    Posts
    5

    Blank Line when using Center Across Selection

    When using Center Across Selection and Wrapping, I get a blank line in the wrapped cell before the cell's contents, after using AutoFit.

    Example before AutoFit:
    ------------------------------
    Cell/row
    ------------------------------
    This is cell/row to wrap with Center Across Selection
    ------------------------------
    Another Cell/row
    ------------------------------


    Example after AutoFit:
    ------------------------------
    Cell/row
    ------------------------------

    This is cell/row to wrap with
    Center Across Selection
    ------------------------------
    Another Cell/row
    ------------------------------


    Hopefully I'm explaining this ok.

    Thanks for any help.

    Jon

  2. #2
    Registered User
    Join Date
    01-09-2012
    Location
    Stephens City, VA
    MS-Off Ver
    Excel 2007
    Posts
    5

    Re: Blank Line when using Center Across Selection

    After fiddling with it this morning, I have a more information to offer.

    I have several cells on a row, merged with wrapping. Autofit (obviously) will not work. So what I did is to create a macro that turns the merge off, centers across selection, autofits, saves the new row height, turns merge back on, and then sets the correct row height. This works on screen most all the time. However, when printed or using print view, the pesky blank line is appearing in the cell. This sometimes happens on screen. But most of the time, it looks perfect on screen but contains the blank line when printed.

    I've tested this by manually going through the same steps as the macro to make sure there wasn't something in my VBA code messing things up. But it happens with or without the macro. But it only happens with the merged cells.

    AND ... I get the exact same issue when using just center across selection (no merging). Looks fine on screen but extra blank line when printing.

    It "appears" to be unrelated to merging and the macro since it also does it with simply center across selection. Quite a few merged cells on the sheet have this issue when printing (or print view) but look fine on screen. Occasionally this also happens on screen.

    Quite frustrating.

    Any thoughts?

    Thank you!
    Jon

  3. #3
    Registered User
    Join Date
    01-09-2012
    Location
    Stephens City, VA
    MS-Off Ver
    Excel 2007
    Posts
    5

    Re: Blank Line when using Center Across Selection

    I know what the problem is (still don't know how to fix it).

    Excel is reformatting the content of wrapped cells (merged or not) when printing (or print viewing). So what I see is not necessarily what I get. After reformatting the content of my trouble cells, Excel seems to think extra space is needed for some reason. The extra line I am getting really isn't an extra line at all. The cells are vertically aligned to "bottom". So when Excel reformats the content, it just appears to be a line above it.

    If I go into those cells and rewrite the content, making it shorter or longer, then Excel doesn't feel the need to resize the row height. Since the content will not be static once I finish the speadsheet, I simply changed the vertical alignment to "top". So if Excel decides to resize in the future, at least the white space will be after instead of before.

    So the final question is this ... is there a way to "lock" the row height so it doesn't change no matter what funky stuff Excel decides to do?

    Thanks!

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

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

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1