C
Chris
I made my own user defined function to act as a test function for me
to try some stuff out in a sub that is being ran from a button.
My test function is
Function testFunc() As Integer
On Error GoTo errhandler
ActiveWorkbook.Names.Add Name:="ZOMGNAME", RefersTo:="=Sheet1!X20"
testFunc = 1
errhandler:
MsgBox Err.Description
End Function
The error I get is application-defined or object-defined error
The function exists in the workbooks Module1 module
Why am I getting the error?
Thanks in advance
to try some stuff out in a sub that is being ran from a button.
My test function is
Function testFunc() As Integer
On Error GoTo errhandler
ActiveWorkbook.Names.Add Name:="ZOMGNAME", RefersTo:="=Sheet1!X20"
testFunc = 1
errhandler:
MsgBox Err.Description
End Function
The error I get is application-defined or object-defined error
The function exists in the workbooks Module1 module
Why am I getting the error?
Thanks in advance