0

当我关注http://msdn.microsoft.com/en-us/library/office/jj873844.aspx并发布(使用 F5)我的应用程序和函数时:

function getAssignments() {
    assignments = PS.EnterpriseResource.getSelf(projContext).get_assignments();

    projContext.load(assignments,
        'Include(Project, Name, ActualWork, ActualWorkMilliseconds, PercentComplete, RemainingWork, Finish, Task)');

    // Run the request on the server.
    projContext.executeQueryAsync(onGetAssignmentsSuccess,
        // Anonymous function to execute if getAssignments fails.
        function (sender, args) {
            alert('Failed to get assignments. Error: ' + args.get_message());
        });
}

我收到以下错误:

错误:GeneralSecurityAccessDenied

你知道为什么吗?我在任何地方都使用属于管理员组的本地帐户。

4

1 回答 1

0

您是否一直关注文章到最后?

有一个 AppManifest.xml 示例,它包含 2 个权限:

   <AppPermissionRequests>
      <AppPermissionRequest Scope="http://sharepoint/projectserver/statusing" Right="SubmitStatus" />
      <AppPermissionRequest Scope="http://sharepoint/projectserver/projects" Right="Read" />
   </AppPermissionRequests>

如果您不授予应用程序这些权限,它无法从项目服务器获取数据并给您错误:GeneralSecurityAccessDenied

于 2014-01-20T10:37:06.690 回答