0
IgnoreFirst (int) 또는 IgnoreLast (int)는 머리말이나 꼬리말로 고정 된 행 수만 무시합니다. 하지만 txt/csv 파일의 특정 줄을 무시하거나 주석을 달고 싶습니다. 다음과 같은 예를 들어 (일부 단락 또는 TXT/CSV에서 특정 라인을 무시) : 나는 BeforeReadRecord 및 SkipThisRecord에 대해 읽고FileHelpers를 사용하여 txt 파일의 행을 주석으로 추가하거나 무시하는 방법
############# This is a comment ##########
/* Some comment paragraph
some more comments
last line of comment */
1,Foo,FooItem1
2,Foo,FooItem2
3,Goo,GooItem3
#4,Doo,DooItem4 <-- ignore.
5,Eoo,EooItem5
잠재적으로이 문제를 해결할 수 있지만 문서는 이미지로 간단하고, 설명이 없거나 예제를 제공하지 않습니다. 기록을 건너 뛸
FileHelperEngine engine = new FileHelperEngine(typeof(Orders));
// set the event here
engine.BeforeReadRecord += new BeforeReadRecordHandler(BeforeEvent);
다음 핸들러에서, 특정 조건을 확인 할 수 있습니다 :