Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Row from address of range
Is is possible to extract just the row number from a range address...
so I have E185 in a variable, How can I get just the 185 into a different variable? Thanks!! |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Row from address of range
On Thu, 21 Apr 2005 18:16:02 -0700, "KyWilde"
wrote: Is is possible to extract just the row number from a range address... so I have E185 in a variable, How can I get just the 185 into a different variable? Thanks!! You could use the Row property: Sub ExtractRow() Dim Adr As Range Set Adr = Range("E185") Debug.Print Adr.Row End Sub --ron |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Row from address of range
If cell is active, var = activecell.row
"KyWilde" wrote: Is is possible to extract just the row number from a range address... so I have E185 in a variable, How can I get just the 185 into a different variable? Thanks!! |
#4
Posted to microsoft.public.excel.programming
|
|||
|
|||
Row from address of range
As given, use the .Row property. There's also the .Column property
Useful too are the .Rows.Count and .Columns.Count properties. For a safe and fast way to copy tables, this is my preferred method... eg copy a named range from one sheet to another... DIM Source as Range DIM Target as Range SET Source = Thisworkbook.Names.Item("MyList").RefersToRange With Source Set Target = _ Worksheets("Sheet2").Range("B2").Resize(.Rows.Coun t,.Columns.Count) Target.Value = .Value End with "KyWilde" wrote: Is is possible to extract just the row number from a range address... so I have E185 in a variable, How can I get just the 185 into a different variable? Thanks!! |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
=HYPERLINK("#"&CELL("address", ADDRESS(MATCH(VALUE(B3),Range ... ? | Excel Worksheet Functions | |||
How to create a range address with ADDRESS function? | Excel Worksheet Functions | |||
Address Range | Excel Worksheet Functions | |||
Deleting Range name's listed in the range address box. | Excel Discussion (Misc queries) | |||
range.address ? | Excel Programming |