LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27
Default Refer to 1 cell relative from named range

Try to retrieve thevalue from 1 cell relative from named range.
Something like this.

Sub test()
Set MyRange = Range("C1:F10")
MyNumber = MyRange.Offset(1, -2).Value
End Sub

However the offset method gives me an array back which is not what I
want. How can I retrieve the value from for example A1 or B1 or C1 with
a relative reference?
MyRange.Cells(1, -2) gives a runtime error. Any suggestions?
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
refer to cell relative to range Horatio J. Bilge, Jr. Excel Discussion (Misc queries) 9 October 26th 07 03:03 PM
Refer a specific cell in a named cell range [email protected] Excel Programming 2 March 13th 06 07:02 PM
???Refer to a specifc cell in a named range Jaylin Excel Worksheet Functions 1 February 10th 06 11:47 AM
How does one refer to the n-1 element of a named range? Charles Hewitt Excel Discussion (Misc queries) 2 November 26th 05 06:56 AM
How do you refer to a dynamic named range? Ian Staines Excel Programming 3 September 14th 03 10:48 PM


All times are GMT +1. The time now is 02:52 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"