Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hello:
I have a RefEdit field with the range 'TaxData'! $B$4:$G$18', I need to figure out the StartRow, StartCol, EndRow, EndCol reference. e.g. $B$4 = Row 4, Col 2 $G$18 = Row 18, 7 is there a VBA function that could return the Row/Col values directly or if some one can point me to a piece of code I can reuse. Thanks in advance, -Neil |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Sub a()
Dim Rg As Range Dim StringRg As String StringRg = "TaxData!$B$4:$G$18" Set Rg = Range(StringRg) Debug.Print "Start row: "; Rg.Row Debug.Print "Start col: "; Rg.Column Debug.Print "End row: "; Rg.Row + Rg.Rows.Count - 1 Debug.Print "End col: "; Rg.Column + Rg.Columns.Count - 1 End Sub -- Jim Rech Excel MVP |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Identify a range of cells containing dates | Excel Worksheet Functions | |||
Identify peaks and troughs in range | Excel Discussion (Misc queries) | |||
VBA, identify a range | Excel Worksheet Functions | |||
Identify User Selected Range | Excel Programming | |||
Identify Range Selected By User | Excel Programming |