InsertLines Method (VBA Add-In Object Model)

Inserts a line or lines of code at a specified location in a block of code.

Syntax

object.InsertLines(line, code) The InsertLines syntax has these parts:

Part Description
object Required. An object expression that evaluates to an object in the Applies To list.
line Required. A Long specifying the location at which you want to insert the code.
code Required. A String containing the code you want to insert.

Remarks

If the text you insert using the InsertLines method is carriage return-linefeed delimited, it will be inserted as consecutive lines.