Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hi All.......
I would like to select a cell with code, say B14, and then be able to assign a RangeName to it's "Current Region" without having to use cell references for the Range because I never know how big the range will be for the selected cell. Any help would be appreciated. Vaya con Dios, Chuck, CABGx3 |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Sub NameThatRegion()
Dim r As Range Set r = ActiveCell.CurrentRegion r.Name = "alphaa" End Sub -- Gary''s Student - gsnu200901 |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Why vector through the variable?
Sub NameThatRegion() ActiveCell.CurrentRegion.Name = "alpha" End Sub -- Rick (MVP - Excel) "Gary''s Student" wrote in message ... Sub NameThatRegion() Dim r As Range Set r = ActiveCell.CurrentRegion r.Name = "alphaa" End Sub -- Gary''s Student - gsnu200901 |
#4
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Nice improvement Rick........thanks
Vaya con Dios, Chuck, CABGx3 "Rick Rothstein" wrote in message ... Why vector through the variable? Sub NameThatRegion() ActiveCell.CurrentRegion.Name = "alpha" End Sub -- Rick (MVP - Excel) "Gary''s Student" wrote in message ... Sub NameThatRegion() Dim r As Range Set r = ActiveCell.CurrentRegion r.Name = "alphaa" End Sub -- Gary''s Student - gsnu200901 |
#5
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
"Works fine, lasts a long time"
Many thanks "Gary''s Student" Vaya con Dios, Chuck, CABGx3 "Gary''s Student" wrote in message ... Sub NameThatRegion() Dim r As Range Set r = ActiveCell.CurrentRegion r.Name = "alphaa" End Sub -- Gary''s Student - gsnu200901 |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Testing For a RangeName | Excel Discussion (Misc queries) | |||
union of RangeName | Excel Programming | |||
Finding Row Numbers Within the RangeName | Excel Programming | |||
Give RELEVANT responses to questions. DO NOT give usless list | Excel Worksheet Functions | |||
RangeName blocks of data | Excel Programming |