ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   Macro Range (https://www.excelbanter.com/excel-discussion-misc-queries/173366-macro-range.html)

mbnspect

Macro Range
 
I have a macro for my spread sheet. When I get to Range, I want to say

Range (J ) .Select

What can I put after the J to have the range always be on whatever active
row that I am currently on, without actually putting the row number down.

Range (JActiveCell) .Select obviously doesn't work. Any ideas. Thank you

carlo

Macro Range
 
Range("J" & activecell.row).select

hth
Carlo

On Jan 17, 2:21*pm, mbnspect
wrote:
I have a macro for my spread sheet. *When I get to Range, I want to say

Range (J *) .Select *

What can I put after the J to have the range always be on whatever active
row that I am currently on, without actually putting the row number down. *

Range (JActiveCell) .Select obviously doesn't work. Any ideas. *Thank you



Rick Rothstein \(MVP - VB\)

Macro Range
 
And another possibility...

Cells(ActiveCell.Row, "J").Select

or

Cells(ActiveCell.Row, 10).Select

Rick


"carlo" wrote in message
...
Range("J" & activecell.row).select

hth
Carlo

On Jan 17, 2:21 pm, mbnspect
wrote:
I have a macro for my spread sheet. When I get to Range, I want to say

Range (J ) .Select

What can I put after the J to have the range always be on whatever active
row that I am currently on, without actually putting the row number down.

Range (JActiveCell) .Select obviously doesn't work. Any ideas. Thank you




All times are GMT +1. The time now is 01:53 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com