Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I created an automation server with custom functions and I want to
allow the usage of named ranges. Normally when using functions and named ranges the cell knows which item in the named range to use. In my automation server the named range is passed as an object array. My function does not know which cell is making the call so how do I know from which cell to pull the text. Am I missing a property of the range object that figures this out or do I need to find some way to pass in the cell from the function is being called from? When I have a range with a single cell, I just grab the text. |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Here is an example:
If my named range is 10 cells in a column (example: MyRange = a1:a10) if I am calling the function from b3 passing in MyRange I will get the a3 value. |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Leo,
In VB, it would be something like: Public Function RangeValue(argNamedRange As Range) As Variant RangeValue = argNamedRange.Range("A1").Offset(Application.Calle r.Row - 1, 0) End Function NickHK "LJ" wrote in message oups.com... Here is an example: If my named range is 10 cells in a column (example: MyRange = a1:a10) if I am calling the function from b3 passing in MyRange I will get the a3 value. |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
reference first cell in a named range | Excel Worksheet Functions | |||
automatic range - named range give me circular reference... | Excel Discussion (Misc queries) | |||
Named Range reference via single Cell | Excel Discussion (Misc queries) | |||
named range, offset self-reference | Excel Discussion (Misc queries) | |||
Reference a named range | Excel Programming |