+ Reply to Thread
Results 1 to 2 of 2

multiple active cells, how to selected all coresponding rows

  1. #1
    Registered User
    Join Date
    09-30-2013
    Location
    United States
    MS-Off Ver
    Excel 2010
    Posts
    78

    multiple active cells, how to selected all coresponding rows

    So for example if I have a1, a5, and a6 selected, I want to be able to select row 1, 6, and 7 in one action. Is there a hotkey for this, and if not what macro could I use?

    ActiveCell.EntireRow.Select only gives me one row. I want to be able to select all of them at once

  2. #2
    Forum Guru HaHoBe's Avatar
    Join Date
    02-19-2005
    Location
    Hamburg, Germany
    MS-Off Ver
    work: 2016 on Win10 (notebook), private: 2019 on Win10 (desktop), 2019 on Win11 (notebook)
    Posts
    8,197

    Re: multiple active cells, how to selected all coresponding rows

    Hi, bsapaka,

    there will always be only one ActiveCell but you may rely on the selection you made:
    Please Login or Register  to view this content.
    although I think itīs unnecessary to use Select or Activate in most cases when using VBA.

    Ciao,
    Holger
    Use Code-Tags for showing your code: [code] Your Code here [/code]
    Please mark your question Solved if there has been offered a solution that works fine for you

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. [SOLVED] setting variables for 2 cells on active selected row
    By wanty in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 12-15-2013, 06:00 PM
  2. VBA: formatting cells in multiple columns based on selected rows
    By muckem333 in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 04-06-2011, 01:43 PM
  3. Select rows when multiple cells are selected
    By Chasethewind in forum Excel General
    Replies: 7
    Last Post: 01-18-2011, 01:33 PM
  4. InputBox selects active cell, not selected cells?
    By kidmiuso in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 01-15-2010, 09:50 AM
  5. Check selected cells are right of active cell
    By papata123 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 06-12-2007, 02:10 PM

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