none
SharePoint 2013 Designer error: we can't do that for you because the file is no longer checked out or been deleted.

    Question

  • Hi folks,

    trying to edit the Masterpage in SharePoint 2013 designer by creating a custom masterpage and tying to check in the doc...But, I cant for some reason. Error I am getting here is 

    "we can't do that for you because the file is no longer checked out or been deleted."

    Any Suggestions, please.



    Cheers, R.

    Thursday, March 07, 2013 2:20 PM

Answers

  • Hi SP2010 Pro,

    I proposed you use PowerShell to check in the file.

    function CheckInDocument([string]$url)

    {

    $spWeb = Get-SPWeb $url

    $getFolder = $spWeb.GetFolder(“Master Page Gallery”)

    $getFolder.Files | Where { $_.CheckOutStatus -ne “None” } | ForEach

    {

    Write-Host “$($_.Name) is Checked out To: $($_.CheckedOutBy)”

    $_.CheckIn(“Checked In By Administrator”)

    Write-Host “$($_.Name) Checked In” -ForeGroundColor Green

    }

    $spWeb.Dispose()

    }

    Here’s an example on running the function:

    CheckInDocument http://SP

     

    Thanks,

    Jack


    Jack Gao
    TechNet Community Support

    Tuesday, March 12, 2013 12:53 PM
    Moderator
  • Save the script in a file with extension ps1. Example : test.ps1.

    function CheckInDocument([string]$url)
    
    {
    
    $spWeb = Get-SPWeb $url
    
    $getFolder = $spWeb.GetFolder(“Master Page Gallery”)
    
    $getFolder.Files | Where { $_.CheckOutStatus -ne “None” } | ForEach
    
    {
    
    Write-Host “$($_.Name) is Checked out To: $($_.CheckedOutBy)”
    
    $_.CheckIn(“Checked In By Administrator”)
    
    Write-Host “$($_.Name) Checked In” -ForeGroundColor Green
    
    }
    
    $spWeb.Dispose()
    
    }

    Open the SharePoint Management shell and  load the file and call the function Checkindocument and pass the site url parameter.


    MCTS,MCPD Sharepoint 2010. My Blog- http://www.sharepoint-journey.com
    If a post answers your question, please click "Mark As Answer" on that post and "Vote as Helpful

    Thursday, March 14, 2013 12:13 AM
    Moderator

All replies

  • Hi SP2010 Pro,

    I proposed you use PowerShell to check in the file.

    function CheckInDocument([string]$url)

    {

    $spWeb = Get-SPWeb $url

    $getFolder = $spWeb.GetFolder(“Master Page Gallery”)

    $getFolder.Files | Where { $_.CheckOutStatus -ne “None” } | ForEach

    {

    Write-Host “$($_.Name) is Checked out To: $($_.CheckedOutBy)”

    $_.CheckIn(“Checked In By Administrator”)

    Write-Host “$($_.Name) Checked In” -ForeGroundColor Green

    }

    $spWeb.Dispose()

    }

    Here’s an example on running the function:

    CheckInDocument http://SP

     

    Thanks,

    Jack


    Jack Gao
    TechNet Community Support

    Tuesday, March 12, 2013 12:53 PM
    Moderator
  • Thank you for your reply here. 

    Please send me the example here, Somehow I dont see the URL of the example you are referring.


    Cheers, R.

    Wednesday, March 13, 2013 9:13 PM
  • Save the script in a file with extension ps1. Example : test.ps1.

    function CheckInDocument([string]$url)
    
    {
    
    $spWeb = Get-SPWeb $url
    
    $getFolder = $spWeb.GetFolder(“Master Page Gallery”)
    
    $getFolder.Files | Where { $_.CheckOutStatus -ne “None” } | ForEach
    
    {
    
    Write-Host “$($_.Name) is Checked out To: $($_.CheckedOutBy)”
    
    $_.CheckIn(“Checked In By Administrator”)
    
    Write-Host “$($_.Name) Checked In” -ForeGroundColor Green
    
    }
    
    $spWeb.Dispose()
    
    }

    Open the SharePoint Management shell and  load the file and call the function Checkindocument and pass the site url parameter.


    MCTS,MCPD Sharepoint 2010. My Blog- http://www.sharepoint-journey.com
    If a post answers your question, please click "Mark As Answer" on that post and "Vote as Helpful

    Thursday, March 14, 2013 12:13 AM
    Moderator