0

The following code snippet is expected to return the hive path for SharePoint (..\Microsoft Shared\Web Server Extensions\14), instead it returns null.

using Microsoft.SharePoint.Utilities;
string featurePath = SPUtility.GetGenericSetupPath(string.Empty);

What am I missing?

4

1 回答 1

0

SPUtility.GetGenericSetupPath()根据注册表项返回 SharePoint 配置单元路径

HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Shared Tools\Web Server Extensions\14.0\Location

你能检查它的价值吗?

于 2013-09-04T23:32:28.897 回答