OpenXML - Not reading a blank Cell from a row C#
<p>I have an .xlsx file with 3 columns SrNumber,Name,Active in A,B and C columns respectively.</p>

<p>I am reading the content of this file in a DataTable using the source code given in the answer of following question</p>

<p><a href="https://stackoverflow.com/questions/3321082/from-excel-to-datatable-in-c-sharp-with-open-xml">From Excel to DataTable in C# with Open XML</a></p>

<p>I have also did the modificaitons suggested by Sourabh</p>

<p>It works fine when my content is as follows</p>

<pre><code>    A           B       C
1   SrNumber    Name    Active
2   1           test1   Yes
3   2           test2   Yes
4   3           test3   Yes
5   4           test4   Yes
</code></pre>

<p>Now when I am trying to add a row at 6th position I am entering the data only in B6 and C6 cells. <strong>I have not touched A6 Cell.</strong></p>

<p>After running that code I am getting my DataTable filled as follows</p>

<p><a href="https://i.stack.imgur.com/yxxkM.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/yxxkM.png" alt="enter image description here"></a></p>

<p>You can see that value entered in B6 coming in first column and value entered in C6 coming in second column.
Also <code>row.Descendants&lt;Cell&gt;()</code> returning only 2 cells for the newly entered row.</p>

<p>Please let me know if any modifications to be done in the source code.</p>