SharePoint Stack Exchange is a question and answer site for SharePoint enthusiasts. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

We have a number of documents managed in a team site that are organisational policies.

What is the best way of taking documents that have been marked as "approved" in the document library and publish them as HTML (e.g. aspx pages).

I have been thinking I would program a workflow, and use Word Automation services. I see that the Word Automation feature has an output type of "MHTML", but can this be used in a publishing site? If so, how?

Thanks, Richard

share|improve this question

Firstly, lets talk about how to trigger the event of publishing as HTML. There are two options here:

  1. Sharepoint Custom Code Workflow - Your only option in terms of workflow as SP Designer workflows does not allow running of custom code as a Action step. Custom code workflows can get a bit tricky though because of multi threading issues (i've had nightmares while working with these). Still, it can be done.

  2. Custom Sharepoint Event Receiver. Handle ItemUpdated event and check if its publishing approval status = approved. In my view, much easier to work with and much more control.

In your Event Receiver create a class that will take the word document, convert to MHTML using Work Automation Services (read here) and save the HTML back to your publishing site.

Hope this helps.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.