0

I have recently been tasked with a project to convert a LARGE (1000+) amount of Word for Dos (Word 5.5) documents(.doc) that need to be converted / Saved As to a .rtf extension.

The documents are in a folder with sub folders that need to stay intact, so I will need to search to see what files are in folders then open and save as in the same folder format as they were found in but in a different location as a .rtf document.

I have been looking into how to best think of going about such a task, here is what I would like to archive:

Recursive Folder search to a CSV (defined by user or fixed folder location) Create folder structure (same level as folder search, E.g. Converted/folder/sub-folder) Open Files in Word for Dos 5.5 Save As .rtf Log of files converted ( as successful or as failed)

tshepang
  • 12,111
  • 21
  • 91
  • 136
Anton King
  • 75
  • 1
  • 9
  • I have the recursive Folder search working, the bit I am finding difficult in reading the CSV file to open the File in Word 5.5 and then saving the document as RTF. – Anton King Aug 21 '13 at 11:46

2 Answers2

0

I would do this in Word VBA and not VB.Net (see vba and word-vba Stack tags).

Search the web for FileSystemObject() for snippets for iterating over folders, making directories, etc. I would make the destination folders only when you need them so you can tell if you are done processing the source folder so the task is re-startable. Perhaps use a temp folder as destination and then rename/move to the final folder name when source files are all converted.

Record a macro of you doc open and save as steps to use as a model for the core code.

rheitzman
  • 2,247
  • 3
  • 20
  • 36
  • The problem is that I need to open the document in Word for Dos 5.5 and then save the document as RTF, otherwise if i do this in any version of Word there are additional characters that are added, I have looked for a Word for Dos COM Resource, but as of yet I have not found one. – Anton King Aug 21 '13 at 11:44
  • Can you park/poin to a sample file in the cloud (DropBox, etc.) that demonstrates the problem? – rheitzman Aug 21 '13 at 14:38
  • How about buying a solution: http://www.file-convert.com/a_mswd.htm I'd guess there are other options out there. – rheitzman Aug 21 '13 at 14:51
0

Unfortunately I would use the paid converters if I was able but this is something that we are only able to use VB.net for.

I am unable to upload any samples of the documents or errors I can only describe them.

I have since worked out a way around this, I was able to convert the document, using Word 5.5 but it has lost some formatting of the document.

I am in the process on attempting another solution, I will post again if I have any luck.

Anton King
  • 75
  • 1
  • 9