locked
File locked at SharePoint 2007 (MOSS) RRS feed

  • Question

  • Hello,

    I know this forum is for SharePoint 2013, so my sincerely apologies for asking about SharePoint 2007, but I am having an issue and don't know how to solve it.  So thank you in advanced for any help you can provide me.

    I know files have a protection lock time of 10 minutes, and if you get a message that the file is check-out so someone else you just need to wait for 10 minutes according to Microsoft, but in SharePoint 2013 sometimes this has not worked, so I need to run a command like this to unlock the file when the waiting time advise don't work:

    $web =
    get-spweb "SITE URL"

    $list =
    $web.Lists["LIST NAME "]

    $item =
    $list.Items.GetItemById(DOCUMENT ID)

    $item.File.ReleaseLock($item.File.LockId)

    $web.Dispose()

    ***Now this is happening to me at an old environment, the file is not checked out by any person and even if we discard the check-out we got this message:

    "The file <fileName> is checked out or locked for editing by <DomainCredentials> at Microsoft.SharePoint.Library.SPRequestInternalClass.CheckOutFile(String bstrUrl, String bstrWebRelativeUrl, Boolean bCheckoutToLocal, String bstrLastModified)

    at Microsoft.SharePoint.Library.SPRequest.CheckOutFile(String bstrUrl, String bstrWebRelativeUrl, Boolean bCheckoutToLocal, String bstrLastModified)

    I am looking for a method to unlock this file like the one I use in SP 2013, but I have search for it at SP 2007 and I cannot find it. So any help from your side will be highly appreciated.   Thank you again!

    Regards,

    Omar Granados

     

    Thursday, December 15, 2016 11:42 PM

All replies