我正在使用File Helpers 2.9.9,我想知道如何让它跳过坏记录而不是崩溃?
object[] transactions = engine.ReadStream(textReader); // will crash if one record fails.
我也遇到了 DateTime 问题。我不明白为什么它不能使用我设置的格式转换“12/22/2011”。
Error Converting '"12/22/2011"' to type: 'DateTime'. does not match any of the given formats: 'MM/dd/yyyy', 'MM/d/yyyy', 'M/d/yyyy'
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.
Exception Details: FileHelpers.ConvertException: Error Converting '"12/22/2011"' to type: 'DateTime'. does not match any of the given formats: 'MM/dd/yyyy', 'MM/d/yyyy', 'M/d/yyyy'