Question Convert bulk using ofc.exe

  • Wednesday, July 29, 2009 3:47 PM
    Avatar of Jwi-xl
    Jwi-xl
    Avatar of Jwi-xl

    Jwi-xl

    Partner

    0
    Recent Achievements 1 0 0
    First Forums Reply
    (Partner)
    0
     
    Hi,

    I want to convert all excel 97-2003 files in a folder and all sub folders to the new format.

    I have installed MigrationPlanningManager.exe into the system and I have also installed FileFormatConverters.exe (icluding SP2)

    Then I Have configured C:\OMPM\ofc.ini, I only have changed the follwing lines:
    [RUN]
    ; LogDestinationPath: the path where the log files will be written to
    LogDestinationPath=C:\OMPM\OFCLogs
    [FoldersToConvert]
    fldr=d:\temp
    [ConversionInfo]
    SourcePathTemplate=*\*\*\
    DestinationPathTemplate=\*1\*2\*3\converted

    Then I start C:\ompm\Tools\ofc.exe, 

    .. and it works fine,  ....  except a couple of things :

    1) I expected a log file  in C:\OMPM\OFCLogs, but this directory stays empty :((
        I have some files Password protected, that are not converted, and expted this ifo in the logfile.

    2) Is there a way to select only excel files for conversion?
         I Do not want to convert the *.doc and *.ppt files in these directory's.

    3) Is there a way to move the original files that are converted to a other directory, to be sure you do not have 2 versions and you can continue working on converted files only (I want to merge the original directory and de converted directory).

    thi, Johan 

All Replies

  • Wednesday, August 05, 2009 4:02 AM
    Avatar of goodol
    goodol
    Avatar of goodol

    goodol

    175
    Recent Achievements 5 0 0
    Forums Answerer I Forums Replies II Forums Replies I
    175
     
    Hi Johan,
    You may tried this tool: B2XTranslator (introduction), developed by MS Interoperability team.
  • Monday, August 10, 2009 10:49 AM
    Avatar of mrdivo
    mrdivo
    Avatar of mrdivo

    mrdivo

    45
    Recent Achievements 4 0 0
    First Helpful Vote Forums Replies I First Marked Answer
    45
     Has Code
    If you feel that the OMPM interface using an ini-file is too difficult to use, then this might be an interesting alternative: It is possible to use the Office Compatibility Pack directly to convert single binary Office documents to OpenXML on the command line. It goes without saying that this technique can also be used for simple batch conversions.

    This is how to use it (OMPM actually calls the executables below):

    Word:

    		    "C:\Program Files\Microsoft Office\Office12\wordconv.exe" -oice -nme <input file> <output file>

    Excel:

    		    "C:\Program Files\Microsoft Office\Office12\excelcnv.exe" -oice <input file> <output file>

    PowerPoint:

    		    "C:\Program Files\Microsoft Office\Office12\ppcnvcom.exe" -oice <input file> <output file>

    Please note that:
    • You will at least need version 3.0 of the Compatibility Pack, an Office installation however is not required.
    • The command line interface is not officially documented (might change in the future).
    • The full file path to input and output documents has to be specified on the command line.

    A batch conversion would look like this:

    		    for %F in (*.xls) do "c:\Program Files\Microsoft Office\Office12\excelcnv.exe" -nme -oice "%~fF" "%~fF"x 
  • Tuesday, August 18, 2009 3:01 PM
    Avatar of Jwi-xl
    Jwi-xl
    Avatar of Jwi-xl

    Jwi-xl

    Partner

    0
    Recent Achievements 1 0 0
    First Forums Reply
    (Partner)
    0
     
    Its not that the ofc.exe tool and the ini file is difficult to use, but I expect that the indicated logging directory should hold an logging of the conversion, at leat an logging of files that are not converted.
  • Wednesday, September 02, 2009 4:25 PM
    Avatar of Roman Prytkov
    Roman Prytkov
    Avatar of Roman Prytkov

    Roman Prytkov

    0
    Recent Achievements 1 0 0
    First Forums Reply
    0
     
    In http://www.oooninja.com/2008/02/office-compatibility-pack-review.html I read that

    "C:\Program Files\Microsoft Office\Office12\wordconv.exe" -oice -nme <input file> <output file>

    can convert DOCX -> DOC. But in fact it does DOC->DOCX conversion.

    Does anybody know command parameters to do DOCX -> DOC conversion?
  • Thursday, October 22, 2009 2:58 PM
    Avatar of SurFa
    SurFa
    Avatar of SurFa

    SurFa

    0
    Recent Achievements 1 0 0
    First Forums Reply
    0
     
    here is the aswer to your question, combined with an acceptable solution. You can extract the error lines from the report e.g. with an access query etc.: http://channel9.msdn.com/wiki/OfficeDeployment/Troubleshooting/
  • Tuesday, January 19, 2010 1:40 PM
    Avatar of Tushar Mishra
    Tushar Mishra
    Avatar of Tushar Mishra

    Tushar Mishra

    0
    Recent Achievements 1 0 0
    First Forums Reply
    0
     

    Dear Johan,

    I am also doing migration from office 2003 to 2007 , i am using ofc.exe  for the same .This utilty woking with only excel and word file , it can't convert the access and powerpoint files and also  it increase duplication of the files because it create new file while coverting any file. 
    Is there any option in which i can convert the source file and it cannot create new duplicate file and also please tell me how to convert the ppt and access files by this tool. 

  • Wednesday, October 13, 2010 7:57 PM
    Avatar of alabeaty
    alabeaty
    Avatar of alabeaty

    alabeaty

    0
    Recent Achievements 1 0 0
    First Forums Reply
    0
     

    Hi Johan and Tushar Mishra,

    I am also doing a batch migration to office 2007 using ofc.exe  with the same results.  No logfile, and .ppt files are not converting.

    I captured the error msg of one ppt file from the cmd window that opened :

    Error: <filename>.ppt failed to convert 

    (filename taken out here by me for this post)

     

    MrDivo:

    I am going to try your batch conversion syntax for our ppt files in a .bat file and would like more info on the -oice and -nme commands as the sites i've been looking at for the syntax don't seem to have these or any combination of these?

Need Help with Forums? (FAQ)

Statistics

  • Started: 7/29/2009
  • Last Reply: 10/13/2010
  • Helpful Votes: 0
  • Replies: 7
  • Views: 9,982