C# web analysis project
<p>I am working in web analysis project in that i display the metrics in graph for a selected date range. 
For Example: March14-April17 is the date range i have selected in graph x-axis it displaying the date as 14,16,18 skipping the days that is perfect and that is the requirement
When i click the excel export link its exactly taking the x-axis dates as 14,16,18 that should not happen here it has to export the dates as 14,16,17,18........till april 17th in order.</p>

<p>so what should i need to do to fix this issue?</p>

<p>dssource is a variable where the value1,table1,table2 captured from the graph part when exporting </p>

<pre><code>value1-Application name
table1-x-axis dates
table2-values of the metrics binded in graph
</code></pre>

<p>// this is the place where graph  is populated based on  dsweek</p>

<p>private DataSet WeekFilter(DataSet sourceDataSet)
    {
        DataSet dsWeek = new DataSet();
        if (sourceDataSet.Tables[1].Rows.Count &lt;= 30)
            return sourceDataSet;</p>

<pre><code>    int moduleValue = GetBaseModValue(sourceDataSet.Tables[1].Rows.Count);

    #region "Prepare WeekFilterDataSet"
    DataTable dtZeroTable = sourceDataSet.Tables[0].Copy();
    DataTable dtFirstTable = sourceDataSet.Tables[1].Clone();
    DataTable dtSecondTable = sourceDataSet.Tables[2].Clone();
    #endregion

    for (int iRowCount = 0; iRowCount &lt; sourceDataSet.Tables[1].Rows.Count - 1; iRowCount++)
    {
        if (iRowCount % moduleValue == 0)
        {
            dtFirstTable.ImportRow(sourceDataSet.Tables[1].Rows[iRowCount]);
            string Expression = "DataDate='" + sourceDataSet.Tables[1].Rows[iRowCount]["DataDate"] + "'";
            DataRow[] drAddRows = sourceDataSet.Tables[2].Select(Expression);
            foreach (DataRow dr in drAddRows)
            {
                dtSecondTable.ImportRow(dr);
            }
        }
    }
    dsWeek.Tables.Add(dtZeroTable);
    dsWeek.Tables.Add(dtFirstTable);
    dsWeek.Tables.Add(dtSecondTable);
    return dsWeek;
}
</code></pre>

<p>//This Is the code Dssource is the place where the value1,table1,table2 for graph export information is copied to excel export 
 public new StringBuilder PreparesbForExcelExport(DataSet dsSource, string sourceText)
    {
        StringBuilder tbl = new StringBuilder();</p>

<pre><code>    if (dsSource == null || dsSource.Tables.Count == 0)
        throw new Exception("Datasource Not Available");

    if (dsSource.Tables.Count != 3)
        return tbl;


    DataTable XaxisList = null;
    DataTable YaxisList = null;
    DataTable valuesList = null;


    if (dsSource.Tables[0] != null)
        XaxisList = dsSource.Tables[0];
    else
        return tbl;

    if (dsSource.Tables[1] != null)
            YaxisList = dsSource.Tables[1];
        else
            return tbl;

    if (dsSource.Tables[2] != null)
        valuesList = dsSource.Tables[2];
    else
        return tbl;
</code></pre>
