Used to move a file or a folder from one document library to another or from one location to another within the same library.

Note! When moving a folder, all documents and subfolders under that folder will also be moved. The name of the file or folder on the destination can be different from its original name.


MOVE(string sourceListName, string sourceFile, string destinationListName, string destinationFile);

Example: to move the file named helloworld.txt from folder Textfiles in document library Shared Documents to the root folder:

CALL MOVE('Shared Documents', 'Textfiles/helloworld.txt', 'Shared Documents', 'helloworld.txt');

Example: to move the folder named Images from document library Shared Documents to another document library called New Shared Documents:

CALL MOVE('Shared Documents', 'Images', 'New Shared Documents', 'Images');

Code examples

Move document

using (var connection = new SharePointConnection(connectionString))
    using (var command = new SharePointCommand(@"CALL MOVE('Shared Documents', 'Images/bendsoft.jpg', 'Shared Documents', 'bendsoft.jpg')", connection))

Skip Navigation Links.

Visa     MasterCard