Solved

Batch conversion

Posted on 2013-01-02
11
453 Views
Last Modified: 2013-01-02
Running Microsoft Office 2007 on a Windows 7 SP-1 platform, I have a question regarding batch conversion of a file type.   I have around one thousand files in Works 2000 Word Processor format, file extension = .wps.   These files are distributed in dozens, or hundreds of folders.  I would like to convert these documents to .docx files, or even better, create copies of them with .docx extension and retain the original files.   I can convert a single .wps file by opening it in Word 2007 and saving it a s a Word document.  Is there a way to accomplish this en masse, without having to convert each file individually?   The conversion seems to require the Microsoft Office text converter.  If I simply rename the file extension of a .wps file to .docx, it can't be opened in Word due to "corruption."   I can also change the default program for .wps files to Microsoft Word.  But this doesn't save a copy of the .wps file in .docx format, unless each file is opened individually and then saved individually.
0
Comment
Question by:ddantes
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 5
  • 5
11 Comments
 
LVL 3

Expert Comment

by:tsnirone
ID: 38738426
0
 
LVL 13

Expert Comment

by:Yagya Shree
ID: 38738473
First read this post

http://www.groovypost.com/howto/howto/convert-microsoft-works-wps-files-to-word-docx/

If you are able to follow the steps then good.

If not than look into the link below:

Use this online tool to conver them to doc files in mass

http://www.zamzar.com/convert/wps-to-doc/
0
 

Author Comment

by:ddantes
ID: 38738488
Dear tsnirone: Thank you for your comment.  However, that article describes how to install the text converter, which I already have.  I am looking for a method of converting a large number of wps files, in different folders, to docx.  That article would only accomplish one file at a time.  

Dear yagyashree:  Thank you for your comment.  The first post describes how to change the default program associated with the .wps file extension.  I have already done that, and it does allow me to open one .wps file at a time, and save it in .docx format.  However, it doesn't help me perform this function as a batch operation.

Regarding the Zamzar service, it would require collecting and uploading over one thousand files, then receiving the converted files and distributing them to perhaps one hundred folders.  So, unfortunately, it isn't a viable option for me.
0
Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

 
LVL 3

Accepted Solution

by:
tsnirone earned 500 total points
ID: 38738516
Would this way of automatic the wps converter - help:

http://help.wugnet.com/office/Batch-convert-Works-Word-2007-ftopict1116660.html

?
0
 

Author Comment

by:ddantes
ID: 38738546
Thank you for your comment.  I had seen that article.  Although the title of the article uses the phrase "Word 2007", the macro described in the article converts .wps files to .doc in Word 97 format, not .docx Word 2007 format.  Even so, I would have liked to try the macro.  I wasn't able to follow the author's instructions for installing the macro in Word 2007 -- it didn't install.  And if I ran it as a .bat file within a folder containing .wps files, they were not converted.
0
 
LVL 3

Expert Comment

by:tsnirone
ID: 38738589
I am sorry. Out of ideas. I would think that your best bet is the macro way of accessing the converter. It seems to have worked for the other person in that thread. Perhaps try again to install it?

Batch-converting from doc to docx seems a bit easier.
0
 

Author Comment

by:ddantes
ID: 38738648
Understood.  I have now gotten the macro to work, but it converts .wps to .doc (Word 97) instead of .docx (Word 2007).   Can you adjust this macro so that it converts to the correct document type and file type?   I tried changing instances of "DOC" to "DOCX" and it seemed to convert the files to .docx files, but they were corrupted and could not be opened.

Sub Batch_Save_WPS_as_DOC97()
Dim bConv As Boolean
Dim strFileName As String
Dim strDocName As String
Dim strPath As String
Dim oDoc As Document
Dim Response As Long
Dim fDialog As FileDialog

bConv = Options.ConfirmConversions
Options.ConfirmConversions = False
Set fDialog = Application.FileDialog(msoFileDialogFolderPicker)
With fDialog
.Title = "Select folder and click OK"
.AllowMultiSelect = False
.InitialView = msoFileDialogViewList
If .Show <> -1 Then
MsgBox "Cancelled By User", , "Save all as DOC"
Exit Sub
End If
strPath = fDialog.SelectedItems.Item(1)
If Right(strPath, 1) <> "\" Then strPath = strPath + "\"
End With

If Documents.Count > 0 Then
Documents.Close SaveChanges:=wdPromptToSaveChanges
End If

strFileName = Dir$(strPath & "*.wps")

While Len(strFileName) <> 0
Set oDoc = Documents.Open(strPath & strFileName)

strDocName = ActiveDocument.FullName
intPos = InStrRev(strDocName, ".")
strDocName = Left(strDocName, intPos - 1)
strDocName = strDocName & ".doc"
oDoc.SaveAs FileName:=strDocName, _
FileFormat:=wdFormatDocument97
oDoc.Close SaveChanges:=wdDoNotSaveChanges
strFileName = Dir$()
Wend
Options.ConfirmConversions = bConv
End Sub
0
 
LVL 3

Expert Comment

by:tsnirone
ID: 38738662
I'm sorry but I think you need to do it in two steps. First to .doc then from .doc to .docx.

http://blogs.msdn.com/b/ericwhite/archive/2008/09/19/bulk-convert-doc-to-docx.aspx

or

http://www.ehow.com/how_6931626_batch-convert-doc-docx.html
0
 

Author Comment

by:ddantes
ID: 38738698
That's bad news!   The start of the instructions states:  "Move all your ".DOC" files to a single folder".   There are many files, in many folders, and I don't want to be collecting them, processing them, and then redistributing them to their original locations.   Sorry that won't work for me.   I'll post a question under programming to see if someone can edit the macro.
0
 
LVL 3

Expert Comment

by:tsnirone
ID: 38738717
I believe the limitation is not in the macro but in the converter the macro is using.

From:
http://blogs.msdn.com/b/ericwhite/archive/2008/09/19/bulk-convert-doc-to-docx.aspx

I read this:
The SourcePathTemplate and DestinationPathTemplate provide extremely flexible configuration for bulk conversion of a large number of directories.  They allow an IT professional to, say, convert files from one entire server, place the converted files on a different server, and use various sub-paths of the path of the source document to form the path where the DOCX will be placed.  Fully configuring SourcePathTemplate and DestinationPathTemplate is beyond the scope of this blog post.  The configuration above basically specifies to just take all of the DOC files in the specified fldr directory, and place them in the specified DestinationPathTemplate directory.
0
 

Author Closing Comment

by:ddantes
ID: 38738809
An Expert was able to edit the macro so that it converts wps to Word 2007 docx files.  Thank you.
0

Featured Post

[Webinar] Code, Load, and Grow

Managing multiple websites, servers, applications, and security on a daily basis? Join us for a webinar on May 25th to learn how to simplify administration and management of virtual hosts for IT admins, create a secure environment, and deploy code more effectively and frequently.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Introduction This tutorial provides instructions on how to properly format your Word document using the inbuilt tools provided. The benefits of using these tools means your documents are more accessible and easily portable to other applications an…
Using Word 2013, I was experiencing some incredible lag when typing.  Here's what worked for me....
Learn how to make your own table of contents in Microsoft Word using paragraph styles and the automatic table of contents tool. We'll be using the paragraph styles in Word’s Home toolbar to help you create a table of contents. Type out your initial …
Office 365 is currently available in five editions. Three of them are for business use: Office 365 Business Essentials, Office 365 Business, and Office 365 Business Premium. Two of them are for home/personal use: Office 365 Home and Office 365 Perso…

734 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question