Parse with space between commas/quotes #1920
Answered
by
JoshClose
sagicoh1003
asked this question in
Q&A
-
Hey I'm parsing a csv file that looks like this: "Header1","header2" Im getting an exception due to the space after the comma. I wanted to ask if there is a way/configuration to not get an exception and to parse the field correctly? Field1 under header1 and so on.. Thanks This is the stackoverflow link https://stackoverflow.com/questions/70259202/csvhelper-space-between-quotes |
Beta Was this translation helpful? Give feedback.
Answered by
JoshClose
Dec 13, 2021
Replies: 1 comment
-
You can set var config = new CsvConfiguration(CultureInfo.InvariantCulture)
{
TrimOptions = TrimOptions.Trim
}; |
Beta Was this translation helpful? Give feedback.
0 replies
Answer selected by
sagicoh1003
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
You can set
TrimOptions
in the configuration.