Currently my UDF WName()outputs a result in each spreadsheet cell that it was called from.
Now I am focused on developing the last few lines in order to output a second variable ("MinDist") four cells to the right of each UDF call in the spreadsheet.
I'm trying to do this via ActiveCell.Offset., but not getting the result I need. Here's a snipit:
Full spreadsheet and VBA code attached.
Note that for debugging, I'm just looking now at sheet "A", cell "A14"
Any suggestions?
Thanks!
g
Now I am focused on developing the last few lines in order to output a second variable ("MinDist") four cells to the right of each UDF call in the spreadsheet.
I'm trying to do this via ActiveCell.Offset., but not getting the result I need. Here's a snipit:
Code:
WName = MKRTable(MinIndex, WMKR)
'Nice to have: Output the MinDist value four columns to the right of the WName function call. Need ActiveCell.Select?
ActiveCell.Offset(0, 4).Range("A1").Select 'This doesn't work
ActiveCell.Offset(0, 4).Range("A1").Value = MinDist 'This doesn't work
ActiveCell.Offset(0, -4).Range("A1").Select 'This doesn't work
Note that for debugging, I'm just looking now at sheet "A", cell "A14"
Any suggestions?
Thanks!
g