none
List does not exist, when it does.

    Вопрос

  • I have a Workflow created in SharePoint designer that moves a list item from one list to another after an approval. The destination list is restricted to most users. If a user who has permissions for both lists creates a file in the origin list, the workflow kicks off and executes perfectly.

     

    However, if a user who does not have access to the destination list creates an item in the origin list the workflow will get past the approval but then encounter an error. The error log is pasted below, and within the sharepoint workflow it says "Error copying list item" and "List item not found".

     

    This error occurs under the System Account user who has full control over both lists and the site. I was under the impression that workflows execute under the System Account user to allow them to do things beyond the permissions of regular users (hence their power). But I am confused as to why the System Account cannot see the destination list. Any help would be greatly appreciated, I've tried most everything.

     

    Log:

     

    General                        8kh7 High     List does not exist  The page you selected contains a list that does not exist.  It may have been deleted by another user. 
    07/19/2007 11:47:27.40  w3wp.exe (0x136C)                        0x15A4 Windows SharePoint Services    Workflow Infrastructure        72er Medium   Microsoft.SharePoint.SPException: List does not exist  The page you selected contains a list that does not exist.  It may have been deleted by another user. ---> System.Runtime.InteropServices.COMException (0x81020026): List does not exist  The page you selected contains a list that does not exist.  It may have been deleted by another user.     at Microsoft.SharePoint.Library.SPRequestInternalClass.GetListsWithCallback(String bstrUrl, Guid foreignWebId, String bstrListInternalName, Int32 dwBaseType, Int32 dwBaseTypeAlt, Int32 dwServerTemplate, UInt32 dwGetListFlags, UInt32 dwListFilterFlags, Boolean bPrefetchMetaData, Boolean bSecurityTrimmed, Boolean bGetSecurityData, ISP2DSafeArrayWriter p2DWriter, Int32& plRecycleBinCount)     at Microsoft.SharePoint.Library.SPRequest.GetListsWithCallba... 
    07/19/2007 11:47:27.40* w3wp.exe (0x136C)                        0x15A4 Windows SharePoint Services    Workflow Infrastructure        72er Medium   ...ck(String bstrUrl, Guid foreignWebId, String bstrListInternalName, Int32 dwBaseType, Int32 dwBaseTypeAlt, Int32 dwServerTemplate, UInt32 dwGetListFlags, UInt32 dwListFilterFlags, Boolean bPrefetchMetaData, Boolean bSecurityTrimmed, Boolean bGetSecurityData, ISP2DSafeArrayWriter p2DWriter, Int32& plRecycleBinCount)     --- End of inner exception stack trace ---     at Microsoft.SharePoint.Library.SPRequest.GetListsWithCallback(String bstrUrl, Guid foreignWebId, String bstrListInternalName, Int32 dwBaseType, Int32 dwBaseTypeAlt, Int32 dwServerTemplate, UInt32 dwGetListFlags, UInt32 dwListFilterFlags, Boolean bPrefetchMetaData, Boolean bSecurityTrimmed, Boolean bGetSecurityData, ISP2DSafeArrayWriter p2DWriter, Int32& plRecycleBinCount)     at Microsoft.SharePoint.SPListCollection.EnsureListsD... 
    07/19/2007 11:47:27.40* w3wp.exe (0x136C)                        0x15A4 Windows SharePoint Services    Workflow Infrastructure        72er Medium   ...ata(Guid webId, String strListName)     at Microsoft.SharePoint.SPListCollection.EnsureListsData(String strListName)     at Microsoft.SharePoint.SPListCollection.ItemByInternalName(String strInternalName, Boolean bThrowException)     at Microsoft.SharePoint.SPListCollection.GetListById(Guid uniqueID, Boolean bThrowException)     at Microsoft.SharePoint.SPListCollection.get_Item(Guid uniqueID)     at Microsoft.SharePoint.Workflow.SPWinOEWSSService.CopyListItem(Guid id, Guid listId, Int32 itemId, Guid toListId, Boolean overwrite) 
    07/19/2007 11:47:27.54  w3wp.exe (0x136C)                        0x1180 Windows SharePoint Services    General                        8l1n Monitorable An SPRequest object was reclaimed by the garbage collector instead of being explicitly freed.  To avoid wasting system resources, dispose of this object or its parent (such as an SPSite or SPWeb) as soon as you are done using it.  Allocation Id: {47392566-158E-42A3-9EAA-F07B03AD4757}  To determine where this object was allocated, create a registry key at HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Shared Tools\Web Server Extensions\HeapSettings.  Then create a new DWORD named SPRequestStackTrace with the value 1 under this key. 

    19 июля 2007 г. 16:19

Ответы

Все ответы

  •  ryannash wrote:
     I was under the impression that workflows execute under the System Account user to allow them to do things beyond the permissions of regular users (hence their power). But I am confused as to why the System Account cannot see the destination list.

     

    Anyone who has worked with other workflow products would probably expect that...but unfortunately my experience is that I run into problems when the user starting the workflow doesn't have edit access to any list that needs to be updated by the workflow.

     

    I really hope that I am wrong, because as you point out, it's important to the usefulness of workflow for it to be able to perform actions the user isn't allowed to do.  But then, it is also important for the workflow to know who started it so it can do things like "send email to workflow initiator" but apparently Microsoft didn't see the importance of that, either.

     

    Sorry I can't be more helpful, just wanted to share that my experience is similar to yours. (And to park this in my threads list in case anyone does have a better answer.)

    20 июля 2007 г. 16:34
  • Hi,

    Did anyone manage to resolve this?
    I'm getting the same error with a custom workflow that is running under System Account and the workflow was initiated by a user who is logged in as System Account.

     

    It works fine on my development box (as it always does) but crashes on the production server (as it always does Wink ).

    I think the error is crashing around the following code (this is inside my workflow)

     

    Code Block

     

    SPWeb web = new SPSite(workflowProperties.SiteUrl).OpenWeb();

    SPList list = web.Lists[workflowProperties.TaskListID];

     

     

     

    Will put a posting up if I find a solution.

    Thanks

     

    10 октября 2007 г. 14:50
  • resolved it.
    I was using SiteUrl when I should have been using WebUrl so was pointing to the wrong list.
    18 октября 2007 г. 19:43
  • ryannash:

     

    You are partially correct....workflows do run under the "System Account" name, but for SPD-created workflows, they run with the permission set of whoever initiated the workflow.  Visual Studio workflows, on the other hand, run as System Account with true (full) permissions.

     

    See: http://www.kcdholdings.com/blog/?p=119

     

    Dave

     

    19 октября 2007 г. 13:47
  • Perfect, thank you very much Dave, that was exactly the answer I needed. Time to dig deep into VS.

     

    And a personal note, I've got your Apress book on workflows. Extremely helpful.  One of the best books for sharepoint I've read.

    22 октября 2007 г. 15:56
  • So does anyone know if this will be fixed in a service pack