UDF Works in Debug Window but not on Sheet?
I have the following UDF which works when I call it from the debug window
but not on a sheet.
Any ideas?
Public Function GetRole(sRole As String) As Long
Debug.Print "GetRole = " & GetRole
GetRole = Sheets("Settings").Range("stng_Users").Find(sRole) .Row
Debug.Print "GetRole = " & GetRole
End Function
|