# How to Skip lines in CSV in dataport

**URL:** <https://www.dynamicsuser.net/t/how-to-skip-lines-in-csv-in-dataport/53005>\
**Category:** Developers Forum\
**Created:** [May 29, 2014, 7:17am UTC](https://www.dynamicsuser.net/t/how-to-skip-lines-in-csv-in-dataport/53005 "2014-05-29T07:17:06Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![scs\_sathish](https://avatars.discourse-cdn.com/v4/letter/s/3e96dc/32.png) [@scs\_sathish](https://www.dynamicsuser.net/u/scs_sathish)\
**Post date:** [May 29, 2014, 7:17am UTC](https://www.dynamicsuser.net/t/how-to-skip-lines-in-csv-in-dataport/53005/1 "2014-05-29T07:17:06Z")

</div>

Hi all,

while importing Data port i want to skip some lines in csv file… is that possible…??

e.g: im importing purchase line, purchase line has the item no. which does not exist in item master, so error says like–\>item no. does not exist in the related table item…now i want to skip that line & import the remaining line…

thanks & regards,

Sathish.

---

<div class="post-metadata">

**Author:** ![admin1](https://sea1.discourse-cdn.com/flex023/user_avatar/www.dynamicsuser.net/admin1/32/7476_2.png) [@admin1](https://www.dynamicsuser.net/u/admin1)\
**Post date:** [September 30, 2014, 1:51pm UTC](https://www.dynamicsuser.net/t/how-to-skip-lines-in-csv-in-dataport/53005/2 "2014-09-30T13:51:10Z")

</div>

Was posted to Membership Question forum - moved to NAV Development.

---

<div class="post-metadata">

**Author:** ![George\_Love](https://avatars.discourse-cdn.com/v4/letter/g/13edae/32.png) [@George\_Love](https://www.dynamicsuser.net/u/George_Love)\
**Post date:** [October 1, 2014, 12:33pm UTC](https://www.dynamicsuser.net/t/how-to-skip-lines-in-csv-in-dataport/53005/3 "2014-10-01T12:33:33Z")

</div>

On the data item for which you want to skip lines, you can change the AutoSave property to false. Then you’d want to add code to conditionally insert the line in the OnAfterImport trigger.
