Hello,
I am working on a function and I am stuck with the function returning #VALUE!, any help would be greatly appreciated. The function would sort a range from another workbook and then populate an array of unique values from that range. Then the function would return a specific position within the array. It may be important to note that the worksheet names may contain spaces.
For example
Sheet 1 would have the following formulas as examples
=ReturnUnique("sheet 2", A1:A10, 1) cell would display "Text 1"
=ReturnUnique("sheet 2", A1:A10, 3) cell would display "Text 4"
=ReturnUnique("sheet 2", A1:A10, 2) cell would display "Text 2"
Sheet 2 A1:A10 has the following values
Text 1
Text 1
Text 2
Text 4
Text 3
Text 3
Text 6
Text 5
Text 1
Text 2
The array would have filtered the unique values and would contain the following
arrUniques(1) = "Text 1"
arrUniques(2) = "Text 2"
arrUniques(3) = "Text 4"
arrUniques(4) = "Text 3"
arrUniques(5) = "Text 6"
arrUniques(6) = "Text 5"
Here is the function as I have it so far.
![]()
Please Login or Register to view this content.
Bookmarks