1

I am new to Sharepoint. I have a list of files in a document library. Files are placed within the year folder, followed by the sub-folder of month and the day wise sub-folders. I have a list of existing file names (loaded in SP 2013) and new file name in an excel file.

Is there any way to have the file names changed from old to new using REST and JS? Note that the old file names are not the exact match with the files loaded in SP lib.

Eg: old name is a123_yasdfi_123bc in excel and we have to search using "like" operator

5
  • Possible duplicate: sharepoint.stackexchange.com/questions/83382/change-file-name
    – Submits
    Commented Jan 18, 2016 at 10:34
  • Thanks for response. I cant view the complete code in this site shillier.com/archive/2013/03/26/… Can you please let me know the complete actual code ?
    – Vignesh K
    Commented Jan 19, 2016 at 11:23
  • The link is now dead. See the accepted answer in my link. It has links to references for the CopyTo and MoveTo REST functions. You have to use one of these functions to "change" a file's name via REST.
    – Submits
    Commented Jan 19, 2016 at 14:02
  • will that code work even for SP2013? the reason is that we dont have a test evironment.. i have to attempt in production
    – Vignesh K
    Commented Jan 20, 2016 at 6:47
  • Should work in SP2013.
    – Submits
    Commented Jan 20, 2016 at 9:46

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.