Note

Access to this page requires authorization. You can try signing in or .

Access to this page requires authorization. You can try .

TextFieldParser.HasFieldsEnclosedInQuotes Property

Definition

Namespace:
Microsoft.VisualBasic.FileIO
Assembly:
Microsoft.VisualBasic.Core.dll
Assembly:
Microsoft.VisualBasic.dll
Source:
TextFieldParser.vb
Source:
TextFieldParser.vb
Source:
TextFieldParser.vb
Source:
TextFieldParser.vb
Source:
TextFieldParser.vb

Important

Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.

Denotes whether fields are enclosed in quotation marks when a delimited file is being parsed.

public:
 property bool HasFieldsEnclosedInQuotes { bool get(); void set(bool value); };
public bool HasFieldsEnclosedInQuotes { get; set; }
member this.HasFieldsEnclosedInQuotes : bool with get, set
Public Property HasFieldsEnclosedInQuotes As Boolean

Property Value

True if fields are enclosed in quotation marks; otherwise, False.

Examples

This example sets the HasFieldsEnclosedInQuotes property to True for myReader.

FileReader.TextFieldType = Microsoft.VisualBasic.FileIO.FieldType.Delimited
FileReader.Delimiters = New String() {","}
FileReader.CommentTokens = New String() {""}
FileReader.HasFieldsEnclosedInQuotes = True

Remarks

This is an advanced member; it does not show in IntelliSense unless you click the All tab.

If the property is True, the parser assumes that fields are enclosed in quotation marks (" ") and may contain line endings.

If a field is enclosed in quotation marks, for example, abc, "field2a,field2b", field3 and this property is True, then all text enclosed in quotation marks will be returned as is; this example would return abc|field2a,field2b|field3. Setting this property to False would make this example return abc|"field2a|field2b"|field3.

Applies to

See also


Feedback

Was this page helpful?