Command Line to Convert From Any File MS Excel Can Open (Examples)

If a file can be opened by MS Excel, then converting it is straightforward using the 'MS Excel' conversion method (/M1). The example below illustrates converting a dBase IV (DBF) file to an Excel file. Since Excel can open DBF files, they can be converted into any format that Excel supports for 'Save As'. Adjust the example to fit your needs by modifying /F and /C for the appropriate input and output file types. Note: /F is included for consistency but isn't necessary in this specific case and can be left out.

 

Example 1: Convert a dBase IV File To Excel

To convert a single file from dBase IV (DBF) to an Excel use the following syntax:

 

ConvertXLS.EXE /S"C:\in\input.dbf" /T "C:\out\Final.XLS" /C-4143 /F11 /M1 /V

Next we show how to convert a whole folder (and sub-folders /R) of text files (C:\abc\*.DBF) to XLS files located in the same folder. The following syntax would be used for such a case:

 

ConvertXLS.EXE /S"C:\abc\*.dbf" /T "C:\abc\*.XLS" /C-4143 /F11 /M1 /R /V

 

Note: It is highly encouraged that you use the Verbose (/V) switch initially to see what the status of your conversion is and to help you perfect your command line. When in verbose mode the program will tell you what went wrong or right with your command line using message boxes.