Document.WebOptions Property (Word)

Office 2013 and later
GitHub-Mark-64px

Contribute to this content

Use GitHub to suggest and submit changes. See our guidelines for contributing to VBA documentation.

Returns the WebOptions object, which contains document-level attributes used by Microsoft Word when you save a document as a Web page or open a Web page. Read-only.

expression .WebOptions

expression A variable that represents a Document object.

This example specifies that cascading style sheets and Western document encoding be used when items in the active document are saved to a Web page.

Set objWO = ActiveDocument.WebOptions 
objWO.RelyOnCSS = True 
objWO.Encoding = msoEncodingWestern
Show: