Custom Functions > To Find and Resolve Custom Function Name Conflicts
To Find and Resolve Custom Function Name Conflicts
1. Check if the name of a custom function is identical to that of a built-in function name. On the Functions tab, in the Functions group, click All Functions, and then search for the name of your custom function.
2. Check if the name of a custom function is identical to that of another custom function name. Evaluate the system variable CustomFunctions and check if the custom function name appears in more than one row of the returned matrix.
The returned matrix has three columns, with one row per custom function. The first column is the DLL file name, the second column is the name of the custom function, and the third column is a string representation of the custom function object.
The top-down row order represents the reading precedence when a custom function is called. If a custom function name appears in more than one row, then the function closest to the top is invoked.
In the above list of custom functions, function sin, in row 4, has the same name as the built-in function sin.
3. To rename your custom function, assign your custom function a new name, such as sinALT:
You now have access to both versions of the sin function.
• You can evaluate functions without their arguments to verify their origin. For example, if you valuate sinALT and sin you can verify that they call userpack.dll and the built-in function, respectively:
• You can use the above procedure to rename custom functions that have long or counterintuitive names.