TextConnection Members (Excel)

GitHub-Mark-64px

Contribute to this content

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

Contains Service Contract settings that enable Microsoft Excel to connect to a Data Feed data source.

Properties

Name

Description

Application

Returns an Application object that represents the Microsoft Excel application. Read-only.

Connection

Returns or sets a string that contains text file names that enable Microsoft Excel to connect to text data sources. Variant Read/Write

Creator

Returns a 32-bit integer that indicates the application in which the specified object was created. Read-only Long.

Parent

Returns an Object that represents the parent object of the specified TextConnection Object (Excel) object. Read-only.

TextFileColumnDataTypes

Returns or sets an ordered array of constants that specify the data types applied to the corresponding columns in the text file that you’re importing into a query table. The default constant for each column is xlGeneral. Variant. Read/Write

TextFileCommaDelimiter

True if the comma is the delimiter when you import a text file into a query table. False if you want to use some other character as the delimiter. The default value is False. Read/Write Boolean.

TextFileConsecutiveDelimiter

True if consecutive delimiters are treated as a single delimiter when you import a text file into a query table. The default value is False. Boolean Read/Write

TextFileDecimalSeparator

Returns or sets the decimal separator character that Microsoft Excel uses when you import a text file into a query table. The default is the system decimal separator character. Read/Write String.

TextFileFixedColumnWidths

Returns or sets an array of integers that correspond to the widths of the columns (in characters) in the text file that you’re importing into a query table. Valid widths are from 1 through 32767 characters. Read/Write Variant.

TextFileHeaderRow

Returns or sets value that specifies whether or not the first row (from the starting row) should be treated as a header row. Boolean Read/Write

TextFileOtherDelimiter

Returns or sets the character used as the delimiter when you import a text file into a query table. The default value is null. Read/Write String.

TextFileParseType

Returns or sets the column format for the data in the text file that you’re importing into a query table. Read/Write XlTextParsingType Enumeration (Excel)

TextFilePlatform

Returns or sets the origin of the text file you’re importing into the query table. This property determines which code page is used during the data import. Read/write XlPlatform Enumeration (Excel)

TextFilePromptOnRefresh

True if you want to specify the name of the imported text file each time the query table is refreshed. The Import Text File dialog box allows you to specify the path and file name. The default value is False. Read/Write Boolean.

TextFileSemicolonDelimiter

True if the semicolon is the delimiter when you import a text file into a query table, and if the value of the TextConnection.TextFileParseType Property (Excel) property is xlDelimited. The default value is False. Read/Write Boolean.

TextFileSpaceDelimiter

True if the space character is the delimiter when you import a text file into a query table. The default value is False. Read/Write Boolean

TextFileStartRow

Returns or sets the row number at which text parsing will begin when you import a text file into a query table. Valid values are integers from 1 through 32767. The default value is 1. Read/Write Long.

TextFileTabDelimiter

True if the tab character is the delimiter when you import a text file into a query table. The default value is False. Read/Write Boolean

TextFileTextQualifier

Returns or sets the text qualifier when you import a text file into a query table. The text qualifier specifies that the enclosed data is in text format. Read/Write XlTextQualifier Enumeration (Excel)

TextFileThousandsSeparator

Returns or sets the thousands separator character that Microsoft Excel uses when you import a text file into a query table. The default is the system thousands separator character. Read/Write String

TextFileTrailingMinusNumbers

True for Microsoft Excel to treat numbers imported as text that begin with a "-" symbol as a negative symbol. False for Excel to treat numbers imported as text that begin with a "-" symbol as text. Read/Write Boolean

TextFileVisualLayout

Returns or sets a XlTextVisualLayoutType Enumeration (Excel) enumeration that indicates whether the visual layout of the text being imported is left-to-right or right-to-left. Read/Write