I've written a C# automation AddIn whose public functions can be used in Excel formulas. However, I need to guard against invoking these functions from within the Function Wizard (these AddIn functions actually connect to a remote server).

Is there a direct way to know if an AddIn function (written in C#) was invoked from the function wizard One way I'm considering is enumerating the Excel app windows with EnumWindows to see if one of them is the function wizard. Any other more direct ways

Thanks

Yazan D.