Show/Hide Toolbars

EmEditor Help

Navigation: EmEditor Help > Macro Reference > Selection Object > Methods

EmEditor Macro Reference: InsertFromFile Method

Scroll Prev Top Next More
EmEditor Home - EmEditor Help - EmEditor Macro Reference - Selection Object

InsertFromFile Method

Inserts the contents of the specified file at the cursor position.

[JavaScript]

document.selection.InsertFromFile( strFileName, nEncoding, nFlags );

[VBScript]

document.selection.InsertFromFile strFileName, nEncoding, nFlags

strFileName

Specifies the full path and name of the file to be opened.

nEncoding

Selects from the Encoding Constants, or specify any code page used in the Windows Operating System.

nFlags

Specifies a combination of the following values:

eeOpenAllowNewWindow

Opens as a new window if the current document is titled or modified.

eeOpenDetectUnicode

Detects Unicode signature (BOM).

eeOpenDetectUTF8

Detects UTF-8.

eeOpenDetectCharset

Detects HTML/XML Charset.

eeOpenDetectAll

Detects all encodings.

Version

Supported on EmEditor Professional Version 4.00 or later.

Copyright © 2003-2016 by Emurasoft, Inc.