|
StringParserParseStandardCSV Method
|
Parses a line based on a comma as the separator. Commas wrapped in matched double quotes are not separators.
Matched double quotes are normally removed prior to field return. Fields are NOT trimmed of white spaces prior to return.
Namespace: GSF.ParsingAssembly: GSF.Core (in GSF.Core.dll) Version: 2.4.220-beta+a56b2444ff27b37e053039e60f062b99378309bd
Syntax public static string[] ParseStandardCSV(
string inString,
int startIndex = 0,
bool removeResultQuotes = true
)
Public Shared Function ParseStandardCSV (
inString As String,
Optional startIndex As Integer = 0,
Optional removeResultQuotes As Boolean = true
) As String()
public:
static array<String^>^ ParseStandardCSV(
String^ inString,
int startIndex = 0,
bool removeResultQuotes = true
)
static member ParseStandardCSV :
inString : string *
?startIndex : int *
?removeResultQuotes : bool
(* Defaults:
let _startIndex = defaultArg startIndex 0
let _removeResultQuotes = defaultArg removeResultQuotes true
*)
-> string[]
GSF.Parsing.StringParser.ParseStandardCSV = function(inString, startIndex, removeResultQuotes);
View SourceParameters
- inString String
- The string to parse.
- startIndex Int32 (Optional)
- The index in the line from which to start parsing.
- removeResultQuotes Boolean (Optional)
- Set to TRUE to unwrap quotes in returned array vis-a-vis Excel.
Return Value
StringAn array of the parsed strings (the fields within the line)
Remarks The string.split method is about 4 times faster.
See Also