Command line mode (silent run parameters)

Previous Top Next

You can start ReplaceMagic also from command line with pre-configured configuration file. This is practical if you want to automate your document migration like, for example, having tools use to move files from one to other location and after that you want automatically to fix links according to migration details. 

To help with configuration file preparation we introduced option to automatically create XML configuration.

To enable creation of config file from ReplaceMagic in Search&Replace form you can click on "Silent run params" button which will open new form where you will see XML structure containing all options that you set for ReplaceMagic run.

To have full list of parameters prepare everything like that you want to run search&replace:

  1. select location where documents are (Scan Documents) 
  2. enter search&replace strings in Search&Replace form
  3. select areas where changes should be done
  4. run Silent run parameters and copy and paste content of that form to your config file
  5. start application with ReplaceMagic ConfigFile1.xml
  6. as we support start with multiple configuration files you can create them all (of course, you can do that also manually or from any tool that you are using to move files) and then start application with "ReplaceMagic ConfigFile1.xml ConfigFile2xml ... ConfigFileX.xml". It is important to have just SPACE between configuration files. 


  • Full document scan - per default command line mode works as ultra fast scanning which means that only documents are listed. With this option you can instruct ReplaceMagic to do normal scan where every document is analyzed and links are reported.
  • Encrypt connect data (SharePoint only) - if this parameter is set ReplaceMagic will encrypt username and password used to connect to SharePoint to reduce riskif somebody has access to configuration file as everything else will be saved in plain text
  • Export result files - after silent run is done ReplaceMagic will export content of all tabs to Excel files. Files should be stored in C:\Users\Your_User\AppData\Roaming\ReplaceMagic under name of config filename plus "_ScanDocuments_TIMESTAMP.xlsx" and "_SearchAndReplace_TIMESTAMP.xlsx"
  • Send results file per email - with this option ReplaceMagic will send exported processing results on email configured over Configuration => Notifications

To have complete file set all options how you need them for normal search&replace process and generate this file which you can use afterwards to start ReplaceMagic from command prompt or to generate with any other tool XML file in ReplaceMagic readable format.

This option is frequently used for automation of document migration process.

Remark: CommandPrompt run will work only for selected location which are SharePoint Sites or Document Libraries. It will process also list and list item hyperlinks if they are part of selected site(s) but if you directly select SharePoint list(s) they cannot (yet) be processed during command mode run.

Additional info:

  • Extended CommandLine parameters file with 2 undocumented parameters that can be added before closing XML tag </COMMANLINEPARAMETERS>:

    Those 2 parameters will overwrite document processing timeout parameters in ReplaceMagic configuration file and have to be added manually directly into silent run file.