Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Multi Word docs on the web

Status
Not open for further replies.

meltingpot

Technical User
May 11, 2004
118
GB
Heres the problem ...

I have 150 seperate word documents that are read as as one large document. I dont have any control in changing this, not my dept.

Document 1 contains an index which refers to the other documents in the pool of 150.

I need these to be published on our web site.

Any ideas !!!!

 
Quick and ugly:

From the menu, select File --> Save As --> and select Web Page from the Save As Type dropdown.

< M!ke >
Acupuncture Development: a jab well done.
 
Very ugly, yes! [shocked]

If you have Word 2003 at your disposal, then at least use this and "Save as Web page (filtered)"
That will remove at least a few of the totally unnecessary Office tags...

Record this action once with your macro recorder, then put it in a loop like this:
Code:
Dim i as integer, doc as document
With Application.FileSearch
  .LookIn=[your folder]
  .FileType=msoWordDocuments
  .FileName="*.doc"
  .SearchSubfolders=True 'or False whatever fits
  .Execute
End With

For i=1 to Application.FileSearch.FoundFiles.Count 
  set doc=documents.open(Application.FileSearch.FoundFiles(i))
  doc.SaveAs wdWebPageFiltered '(Or whatever its name may be)
  doc.close
next i

set doc=Nothing
End Sub

Quick and dirty and not tested.
;-)

[blue]Help us, join us, participate
IAHRA - International Alliance of Human Rights Advocates[/blue]
 
P.S: I highly recommend you only use this as a temprary workaround.

Technically, the files will be anything but clean.

Use the time, this quick/dirty solution gives you to create lean, clean and mean HTML or XML templates from scratch.

Bandwidth will thank you for reducing loading time to a tenth, and browsers will thank you for having properly coded documents.

AND: customers will thank you for being professional!
[tongue]

[blue]Help us, join us, participate
IAHRA - International Alliance of Human Rights Advocates[/blue]
 
Thanks guys, ill give it all go. Word is very verbos in convertion to web pages so ill watch that ...

I did us the batch converter but created a lot of files and folders...
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top