Home » SharePoint 2010 » Word Viewer in Sandbox

Word Viewer in Sandbox

So, I was working with a client’s farm this evening. They had recently asked me to install Office Web Apps to the farm, and I had obliged, verifying that the Word Viewer had worked without issue.

Yesterday, I get a call from the same client. He states that some of his documents won’t render in the browser.

Doing a mild bit of browsing/troubleshooting, I ran across a blog entry that seemed to indicate that non-DOCX versions of Word documents would not display properly. Sounds plausible, so I passed that along.

The next day, I get a call that DOCX documents are also misbehaving. Checking back in with my site that I had previously visited, I see that all appears to be well. Going to the site where the client is having issue, I found that all was indeed NOT well.

When I tried to access the document via the browser, Word Viewer responds with the most generic error message possible, “Word Web App cannot open this document for viewing due to an unexpected error” – UGH. And of course, there is the obligatory Correlation Error ID; good, I’ll use that in a bit.

I don’t know if you’ve ever gone looking for this error (remember, I said it _is_ generic), but causes of this particular symptom range from misconfigured Service Applications to Database Access. Not wanting to believe either of these were my issue, I went to the ULS for answers.

Keying the Correlation ID into ULSViewer, I see the following issue:

Figure 1 - Conversion Error in ULS Logs

Figure 1 – Conversion Error in ULS Logs

[By the way, if you admin a SharePoint Farm and you haven’t tried ULSViewer, you’re working WAY too hard – here’s the URL, make sure to click the download button – it’s FREE]

OK, back to our issue/screenshot. What the heck does that mean?!? I went digging and found this post by James Boman. He explains that the Word Viewer runs in the sandbox (no, I don’t know why it would either), and that this limitation causes the Silverlight conversion of Word documents to sometimes fail outright.

Per Boman and several other sources, you can set the WordServerIsSandboxed property to “false” by running a simple set of PowerShell commands. Before you begin this process, you need to know that completing this change will require an IISRESET
(brief outage for your farm):

First, set a variable for your Word Viewing service application:

$e = Get-SPServiceApplication | where {$_.TypeName.Equals(“Word Viewing Service Application”)}

Next, check the existing sandbox status of your service by reviewing the WordServerIsSandboxed property:


Change the existing sandbox status of your service (set the value of the property to “false”):

$e.WordServerIsSandboxed = $false

Verify the changed property:


And finally, perform an IISRESET to have this change take effect:


At this point, your document should successfully display within the web browser using Word Viewer; if not, check the TechNet articles and see what you may have misconfigured.