Thank you Peter & Chip:
I am trying to help a buddy speed up a very slow macro. Part of her macro
locates the value in the last cell in a range. She does this by looping thru
the range. This MIGHT be necessary if the range is dis-joint.
If, however, the range is not dis-joint (so there are no commas in the
address), then no loop should be needed. She can just SPLIT() the address on
colon and pickup the second element as the address of the terminal item.
Thanks again
--
Gary''s Student - gsnu200793
"Peter T" wrote:
Another one -
Set r = Range("a3:c2:e3:e4:a6:a1")
Debug.Print r.Address(0, 0) ' A1:E6
Although you can make a range with such an address you are probably right
that any returned address that does not contain a comma will contain at most
one colon, ie a single area.
Regards,
Peter T
"Chip Pearson" wrote in message
...
It is not safe to make that assumption. The space character in an address
indicates Intersection, so you could have an address with two colons and
no
commas.
Set R = Range("A1:C5 B5:D10")
Debug.Print R.Address ' displays B5:C5
--
Cordially,
Chip Pearson
Microsoft Most Valuable Professional
Excel Product Group
Pearson Software Consulting, LLC
www.cpearson.com
(email on web site)
"Gary''s Student" wrote in
message
...
Is is safe to assume that if the address of a range does not contain a
comma,
that it can contain at most one colon??
--
Gary''s Student - gsnu200793