02-07-2024, 08:16 PM
(02-07-2024, 05:48 PM)SMcNeill Wrote: See the ribbon of buttons above your post area? Click the last button on the right. That's all you usually need to do.
...
See how pretty that shows up, if you just click the VIEW SOURCE button (Ctrl-Shift-S) *before* pasting into the forums?
Let me give it a try...
You can use Application.Caller, but you would probably be best to pass the cell to the function.
With Application.Caller
CallerRows = .Rows.Count
CallerCols = .Columns.Count
CallerAddr = .Address
End With
See: http://www.cpearson.com/excel/WritingFun...InVBA.aspx
To pass the cell:
=SomeFunction(A1)
Where the code has:
SomeFunction(r)
Well that was easy... Thank you sir!