Parameter descriptions for operating the word application. Documents. Open Method

Source: Internet
Author: User
Open Method

Syntax 1: Open the specified file and add it to the document set. Returns the Document Object.

Syntax 2: Open the specified object. When applied to a subfile or recentfile object, syntax 2 returns a Document Object.

Syntax 1

Expression. Open (filename, confirmconversions, readonly, addtorecentfiles, passworddocument, passwordtemplate, revert, writepassworddocument, writepasswordtemplate, format, encoding, visiable)

Syntax 2

Expression. Open

Expression syntax 1: required. This expression returns a file object.

Syntax 2: required. This expression returns an oleformat, recentfile, sub-document, or version object.

Filename is required. ).

Confirmconversions variant type. Optional. The convert file dialog box is displayed. If the file is not in Microsoft Word format.

Readonly variant type. Optional. You can only open the file in read-only mode.

Addtorecentfiles variant type. Optional. Add the real file name to the list of recently used files at the bottom of the File menu.

Passworddocument variant type, optional. The password for opening the file.

Passwordtemplate variant type, optional. In the open template password.

Revert variant type. Optional. Control what will happen if the name is an open document file name. Abandon any unsaved changes in the open document and re-open the file. False activation of open documents.

Writepassworddocument variant type. Optional. Used to save the change password for the document.

Writepasswordtemplate variant type. Optional. The password used to save and change the template.

Format variant type. Optional. This file converter is used to open this document. It can be one of the following wdopenformat constants: wdopenformatallword, wdopenformatauto, wdopenformatdocument, wdopenformatencodedtext, wdopenformatrtf, wdopenformattemplate, wdopenformattext, plain, or wdopenformatwebpages. The default value is wdopenformatauto.

To specify an external file format, use the openformat attribute 1 fileconverter object to determine the value to be used.

Encoding variant type. Optional. The file encoding (code page or character set), used by Microsoft Word when you view the saved document. It can be any valid msoencoding. For a list of valid msoencoding constants, see the Visual Basic Editor Object Browser. The default is the system code page. Read/write dragon.

Visiable variant type. Optional. True. If the file is opened, it is displayed in a visible window. The default value is true.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.