This question arises as a result of this question, but I thought I would split it out into its own.
Anything using SPUtility.GetGenericSetupPath()
is returning null, e.g.
SPUtility.GetGenericSetupPath("config")
SPUtility.GetGenericSetupPath(string.Empty)
both return null. If I make those calls in a little console app and debug it in VS2008, it appears to execute fine with no exceptions (albeit with null returned from the method.) However I notice a message in the output window:
A first chance exception of type 'System.DllNotFoundException' occurred in Microsoft.SharePoint.dll
So if I get Visual Studio to break on all exceptions, even handled ones, the exception is as follows:
System.DllNotFoundException: Unable to load DLL 'onetnative.dll': The specified module could not be found. (Exception from HRESULT: 0x8007007E)
I've checked and onetnative.dll does exist in C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\12\BIN.