Return row number of active cell

Thanks Thanks:  0
Likes Likes:  0
Results 1 to 4 of 4

Thread: Return row number of active cell

  1. #1
    Board Regular
    Join Date
    May 2002
    Location
    Bristol, England
    Posts
    53
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default Return row number of active cell

     
    Could anyone help me with some vba code to give the row number that the current active cell is on.

    Many thanks
    Roger Marshall

  2. #2
    MrExcel MVP fairwinds's Avatar
    Join Date
    May 2003
    Posts
    8,637
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default Re: Return row number of active cell

    Hi,

    a = ActiveCell.Row
    "Fair Winds and Following Seas"

  3. #3
    MrExcel MVP parry's Avatar
    Join Date
    Aug 2002
    Location
    Wellington, New Zealand
    Posts
    3,355
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default Re: Return row number of active cell

    Code:
    Sub RowNum()
    MsgBox "The active cell row is " & ActiveCell.Row
    End Sub

  4. #4
    Board Regular
    Join Date
    May 2002
    Location
    Bristol, England
    Posts
    53
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default Re: Return row number of active cell

      
    Thank you for the lightening fast reply - I had a feeling it was quite simple but I don't quite know enough vba yet to figure it out.
    Roger Marshall

User Tag List

Like this thread? Share it with others

Like this thread? Share it with others

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  

 

 
DMCA.com