Add a line in a txt file
<p>I have a txt file with data such as the following:</p>

<pre><code>:10FF800000040B4E00040B4E00047D1400047D148D
:10FF900000040B4E0004CF6200040B4E00040B4E15
:10FFA00000040B4E00040B4E00040B4E00040B4EDD
:10FFB00000047D1400047D1400047D1400047D14ED
:10FFC00000040B4E000000000000000000000000D4
:10FFD0000000000000040B4E0000000000000000C4
:10FFE0000000000000000000000000000000000011
:10FFF0000000000000000000060000000000BFF844
:020000020000FC
:020000040014E6
:043FF0005AC8A58C7A
:00000001FF
</code></pre>

<p>what I want to do with my C# program is to add a line after or before a specific line, lets say add the line:</p>

<pre><code>:020000098723060
</code></pre>

<p>before this line:</p>

<pre><code>:020000020000FC
</code></pre>

<p>I have tried using the File.ReadLines("file.txt").Last(); but that just gives me the last one, what if i want the third or fourth? also, is there any way to identify the ":" in the file?</p>
