+ Reply to Thread
Results 1 to 10 of 10

Border In Each Page Break

Hybrid View

  1. #1
    Registered User
    Join Date
    06-08-2009
    Location
    SET
    MS-Off Ver
    Excel 2002
    Posts
    12

    Border In Each Page Break

    Bottom border each page, Any suggestions?

    Any Help will be highly appreciated,

    Thanks in advance
    Last edited by dccdvb; 06-09-2009 at 04:11 PM.

  2. #2
    Forum Expert NBVC's Avatar
    Join Date
    12-06-2006
    Location
    Mississauga, CANADA
    MS-Off Ver
    2003:2010
    Posts
    34,898

    Re: Border In Each Page Break, Any suggestions?

    Could you be so kind as to supply your solution here.. it may help someone in the future searching the same topic.
    Where there is a will there are many ways.

    If you are happy with the results, please add to the contributor's reputation by clicking the reputation icon (star icon) below left corner

    Please also mark the thread as Solved once it is solved. Check the FAQ's to see how.

  3. #3
    Registered User
    Join Date
    06-08-2009
    Location
    SET
    MS-Off Ver
    Excel 2002
    Posts
    12

    Re: Border In Each Page Break

    I need help, Bottom border each page, see attached pic
    Attached Images Attached Images

  4. #4
    Forum Expert NBVC's Avatar
    Join Date
    12-06-2006
    Location
    Mississauga, CANADA
    MS-Off Ver
    2003:2010
    Posts
    34,898

    Re: Border In Each Page Break

    You have the thread marked as Solved

    If all your rows have bottom borders, then you should get the bottom border of the last line on the page.. have you printed to see... sometimes the graphic representation shown on screen in Page Preview does not exactly match what you get on paper.

  5. #5
    Registered User
    Join Date
    06-08-2009
    Location
    SET
    MS-Off Ver
    Excel 2002
    Posts
    12

    Re: Border In Each Page Break

    NBVC, thanks for reply, just to know that I'm totally new to Excel

    here's my xls file, please take a look at the attached

    thanks again
    Attached Files Attached Files

  6. #6
    Forum Expert NBVC's Avatar
    Join Date
    12-06-2006
    Location
    Mississauga, CANADA
    MS-Off Ver
    2003:2010
    Posts
    34,898

    Re: Border In Each Page Break

    I see what you want.. you want bold border to automatically be inserted at bottom of each page...

    not sure you can do that... maybe someone can figure it out with VBA... but I am not sure Excel native functionality can do that...

  7. #7
    Registered User
    Join Date
    06-08-2009
    Location
    SET
    MS-Off Ver
    Excel 2002
    Posts
    12

    Re: Border In Each Page Break

    Quote Originally Posted by NBVC View Post
    I see what you want.. you want bold border to automatically be inserted at bottom of each page...

    not sure you can do that... maybe someone can figure it out with VBA... but I am not sure Excel native functionality can do that...
    that's what im talking about, is it possible to do it?

  8. #8
    Registered User
    Join Date
    06-08-2009
    Location
    SET
    MS-Off Ver
    Excel 2002
    Posts
    12

    Re: Border In Each Page Break

    Still need help with this question, please

  9. #9
    Forum Expert martindwilson's Avatar
    Join Date
    06-23-2007
    Location
    London,England
    MS-Off Ver
    office 97 ,2007
    Posts
    19,320

    Re: Border In Each Page Break

    one of andy popes taken from ozgrid
    Sub BorderPages() 
         
        Dim rngBorder As  Range 
        Dim lngLastRow As Long 
        Dim lngLastCol As Long 
        Dim lngHPBreak As Long 
        Dim lngVPBreak As Long 
        Dim lngRow As Long 
        Dim lngCol As Long 
        Dim rngAC As Range 
         
        With ActiveSheet 
            Set rngAC = ActiveCell 
            lngLastRow = .UsedRange.Cells(.UsedRange.Rows.Count, 1).Row 
            lngLastCol = .UsedRange.Cells(1, .UsedRange.Columns.Count).Offset(1, 0).Column 
            .Cells(lngLastRow + 1, 1).Activate 
             
            lngRow = 1 
            For lngVPBreak = 1 To .VPageBreaks.Count 
                lngCol = 1 
                For lngHPBreak = 1 To .HPageBreaks.Count 
                    Set rngBorder = .Range(.Cells(lngRow, lngCol), _ 
                    .Cells(.HPageBreaks(lngHPBreak).Location.Row - 1, .VPageBreaks(lngVPBreak).Location.Column - 1)) 
                    rngBorder.BorderAround xlContinuous, xlThick 
                    lngRow = .HPageBreaks(lngHPBreak).Location.Row 
                Next 
                 
                Set rngBorder = .Range(.Cells(lngRow, lngCol), .Cells(lngLastRow, .VPageBreaks(lngVPBreak).Location.Column - 1)) 
                rngBorder.BorderAround xlContinuous, xlThick 
                 
                lngCol = .VPageBreaks(lngVPBreak).Location.Column 
            Next 
            lngRow = 1 
            For lngHPBreak = 1 To .HPageBreaks.Count 
                Set rngBorder = .Range(.Cells(lngRow, lngCol), _ 
                .Cells(.HPageBreaks(lngHPBreak).Location.Row - 1, lngLastCol)) 
                rngBorder.BorderAround xlContinuous, xlThick 
                lngRow = .HPageBreaks(lngHPBreak).Location.Row 
            Next 
            Set rngBorder = .Range(.Cells(lngRow, lngCol), .Cells(lngLastRow, lngLastCol)) 
            rngBorder.BorderAround xlContinuous, xlThick 
            rngAC.Activate 
        End With 
         
    End Sub
    "Unless otherwise stated all my comments are directed at OP"

    Mojito connoisseur and now happily retired
    where does code go ?
    look here
    how to insert code

    how to enter array formula

    why use -- in sumproduct
    recommended reading
    wiki Mojito

    how to say no convincingly

    most important thing you need
    Martin Wilson: SPV
    and RSMBC

  10. #10
    Registered User
    Join Date
    06-08-2009
    Location
    SET
    MS-Off Ver
    Excel 2002
    Posts
    12

    Re: Border In Each Page Break

    thanks, its works fine but not what i want! all i need just a black border at bottom of each page, and without moving the border if deleting a row from a table? is it possible!?

+ 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