SLK V1.4 run error when i Create an Assignment:"An error occurred. More information may be available in the server event log."

Topics: Developer Forum, User Forum
Oct 27, 2009 at 6:54 AM

On my windows 2008 , I can install and run SLK V1.3.1 successful, and i can install SLK 1.4 ok, but , when i "Create an Assignment",  the system display error: "An error occurred. More information may be available in the server event log."

I goto the evenlog view, found the error log message is below, How should i do the next step? Thank you!

日志名称:          Application
来源:            Windows SharePoint Services 3
日期:            2009/10/27 13:43:26
事件 ID:         0
任务类别task type:          无 (no)
级别class:            错误 (error)
关键字keyword:           经典 (classic)
用户user:            暂缺 (N/A)
计算机:           W2008
说明:
SharePoint Learning Kit Error

Microsoft.SharePoint.SPException: 找不到权限级别。
   在 Microsoft.SharePoint.SPRoleDefinitionCollection.get_Item(String name)
   在 Microsoft.SharePointLearningKit.DropBoxManager.ApplyInstructorReadAccessPermission(SPListItem folder, SPUser instructor)
   在 Microsoft.SharePointLearningKit.DropBoxManager.<>c__DisplayClassd.<CreateAssignmentFolder>b__c()
   在 Microsoft.SharePoint.SPSecurity.CodeToRunElevatedWrapper(Object state)
   在 Microsoft.SharePoint.SPSecurity.<>c__DisplayClass4.<RunWithElevatedPrivileges>b__2()
   在 Microsoft.SharePoint.Utilities.SecurityContext.RunAsProcess(CodeToRunElevated secureCode)
   在 Microsoft.SharePoint.SPSecurity.RunWithElevatedPrivileges(WaitCallback secureCode, Object param)
   在 Microsoft.SharePoint.SPSecurity.RunWithElevatedPrivileges(CodeToRunElevated secureCode)
   在 Microsoft.SharePointLearningKit.DropBoxManager.CreateAssignmentFolder(String docLibTitle, AssignmentProperties assignmentProperties, SlkMemberships slkMembers, String assignmentFolderName)
   在 Microsoft.SharePointLearningKit.ApplicationPages.AssignmentPropertiesPage.SubmitAssignment(Object sender, EventArgs e)
事件 Xml:
<Event xmlns="
http://schemas.microsoft.com/win/2004/08/events/event">
  <System>
    <Provider Name="Windows SharePoint Services 3" />
    <EventID Qualifiers="0">0</EventID>
    <Level>2</Level>
    <Task>0</Task>
    <Keywords>0x80000000000000</Keywords>
    <TimeCreated SystemTime="2009-10-27T05:43:26.000Z" />
    <EventRecordID>2943</EventRecordID>
    <Channel>Application</Channel>
    <Computer>W2008</Computer>
    <Security />
  </System>
  <EventData>
    <Data>SharePoint Learning Kit Error

Microsoft.SharePoint.SPException: 找不到权限级别。
   在 Microsoft.SharePoint.SPRoleDefinitionCollection.get_Item(String name)
   在 Microsoft.SharePointLearningKit.DropBoxManager.ApplyInstructorReadAccessPermission(SPListItem folder, SPUser instructor)
   在 Microsoft.SharePointLearningKit.DropBoxManager.&lt;&gt;c__DisplayClassd.&lt;CreateAssignmentFolder&gt;b__c()
   在 Microsoft.SharePoint.SPSecurity.CodeToRunElevatedWrapper(Object state)
   在 Microsoft.SharePoint.SPSecurity.&lt;&gt;c__DisplayClass4.&lt;RunWithElevatedPrivileges&gt;b__2()
   在 Microsoft.SharePoint.Utilities.SecurityContext.RunAsProcess(CodeToRunElevated secureCode)
   在 Microsoft.SharePoint.SPSecurity.RunWithElevatedPrivileges(WaitCallback secureCode, Object param)
   在 Microsoft.SharePoint.SPSecurity.RunWithElevatedPrivileges(CodeToRunElevated secureCode)
   在 Microsoft.SharePointLearningKit.DropBoxManager.CreateAssignmentFolder(String docLibTitle, AssignmentProperties assignmentProperties, SlkMemberships slkMembers, String assignmentFolderName)
   在 Microsoft.SharePointLearningKit.ApplicationPages.AssignmentPropertiesPage.SubmitAssignment(Object sender, EventArgs e)</Data>
  </EventData>
</Event>

Coordinator
Nov 23, 2009 at 9:49 AM

I fixed the problem in the source code. The uploaded code was using the English names to find the standard roles. I'm now using SPRoleDefinitionType.GetByType which should pick up the correct role regardless of installed language.

This will be in the first official 1.4 release once I've worked through the rest of the bugs.


Richard

SLK Co-ordinator

http://blog.salamandersoft.co.uk

 

Nov 23, 2009 at 10:06 AM

Thank you very very much! I will try it....