none
report viewer not showing data RRS feed

  • Question

  • i m programatically building a datatable and populating that datatable with data from a text file.nw i m assigning that datatable to report viewer but report viewer is not showing any data.here is my code
    if (counter != 0)
    {
    for (int j = 0; j < counter-1; j++)
    {
    fieldValues = file.ReadLine().Split(new char[] { '\t' });
    DataRow dr = dt.NewRow();
    for (int i = 0; i < fieldValues.Length; i++)
    {
    dr[i] = fieldValues[i].ToString();

    }
    dt.Rows.Add(dr);
    }
    }
    reportViewer1.ProcessingMode = Microsoft.Reporting.WinForms.ProcessingMode.Local;
    this.reportViewer1.LocalReport.ReportPath="C:\\Documents and Settings\\amohiuddin\\My Documents\\Visual Studio 2008\\Projects\\sample reporting application\\sample reporting application\\Report1.rdlc";
    this.reportViewer1.LocalReport.ReportEmbeddedResource = "sample reporting.Report1.rdlc";
    this.reportViewer1.LocalReport.DataSources.Clear();
    reportViewer1.DocumentMapCollapsed = true;
    this.reportViewer1.DataBindings.Clear();

    this.reportViewer1.LocalReport.DataSources.Add(rds);


    this.reportViewer1.Show();

    this.reportViewer1.RefreshReport();
    }
    can someone tell me what i m missing?
    i m programatically building a datatable and populating that datatable with data from a text file.nw i m assigning that datatable to report viewer but report viewer is not showing any data.here is my code
    if (counter != 0)
    {
    for (int j = 0; j < counter-1; j++)
    {
    fieldValues = file.ReadLine().Split(new char[] { '\t' });
    DataRow dr = dt.NewRow();
    for (int i = 0; i < fieldValues.Length; i++)
    {
    dr[i] = fieldValues[i].ToString();

    }
    dt.Rows.Add(dr);
    }
    }
    reportViewer1.ProcessingMode = Microsoft.Reporting.WinForms.ProcessingMode.Local;
    this.reportViewer1.LocalReport.ReportPath="C:\\Documents and Settings\\amohiuddin\\My Documents\\Visual Studio 2008\\Projects\\sample reporting application\\sample reporting application\\Report1.rdlc";
    this.reportViewer1.LocalReport.ReportEmbeddedResource = "sample reporting.Report1.rdlc";
    this.reportViewer1.LocalReport.DataSources.Clear();
    reportViewer1.DocumentMapCollapsed = true;
    this.reportViewer1.DataBindings.Clear();

    this.reportViewer1.LocalReport.DataSources.Add(rds);


    this.reportViewer1.Show();

    this.reportViewer1.RefreshReport();
    }
    can someone tell me what i m missing?
    i m programatically building a datatable and populating that datatable with data from a text file.nw i m assigning that datatable to report viewer but report viewer is not showing any data.here is my code
    if (counter != 0)
    {
    for (int j = 0; j < counter-1; j++)
    {
    fieldValues = file.ReadLine().Split(new char[] { '\t' });
    DataRow dr = dt.NewRow();
    for (int i = 0; i < fieldValues.Length; i++)
    {
    dr[i] = fieldValues[i].ToString();

    }
    dt.Rows.Add(dr);
    }
    }
    reportViewer1.ProcessingMode = Microsoft.Reporting.WinForms.ProcessingMode.Local;
    this.reportViewer1.LocalReport.ReportPath="C:\\Documents and Settings\\amohiuddin\\My Documents\\Visual Studio 2008\\Projects\\sample reporting application\\sample reporting application\\Report1.rdlc";
    this.reportViewer1.LocalReport.ReportEmbeddedResource = "sample reporting.Report1.rdlc";
    this.reportViewer1.LocalReport.DataSources.Clear();
    reportViewer1.DocumentMapCollapsed = true;
    this.reportViewer1.DataBindings.Clear();

    this.reportViewer1.LocalReport.DataSources.Add(rds);


    this.reportViewer1.Show();

    this.reportViewer1.RefreshReport();
    }
    can someone tell me what i m missing?
    i m programatically building a datatable and populating that datatable with data from a text file.nw i m assigning that datatable to report viewer but report viewer is not showing any data.here is my code
    if (counter != 0)
    {
    for (int j = 0; j < counter-1; j++)
    {
    fieldValues = file.ReadLine().Split(new char[] { '\t' });
    DataRow dr = dt.NewRow();
    for (int i = 0; i < fieldValues.Length; i++)
    {
    dr[i] = fieldValues[i].ToString();

    }
    dt.Rows.Add(dr);
    }
    }
    reportViewer1.ProcessingMode = Microsoft.Reporting.WinForms.ProcessingMode.Local;
    this.reportViewer1.LocalReport.ReportPath="C:\\Documents and Settings\\amohiuddin\\My Documents\\Visual Studio 2008\\Projects\\sample reporting application\\sample reporting application\\Report1.rdlc";
    this.reportViewer1.LocalReport.ReportEmbeddedResource = "sample reporting.Report1.rdlc";
    this.reportViewer1.LocalReport.DataSources.Clear();
    reportViewer1.DocumentMapCollapsed = true;
    this.reportViewer1.DataBindings.Clear();

    this.reportViewer1.LocalReport.DataSources.Add(rds);


    this.reportViewer1.Show();

    this.reportViewer1.RefreshReport();
    }
    can someone tell me what i m missing?
    i m programatically building a datatable and populating that datatable with data from a text file.nw i m assigning that datatable to report viewer but report viewer is not showing any data.here is my code
    if (counter != 0)
    {
    for (int j = 0; j < counter-1; j++)
    {
    fieldValues = file.ReadLine().Split(new char[] { '\t' });
    DataRow dr = dt.NewRow();
    for (int i = 0; i < fieldValues.Length; i++)
    {
    dr[i] = fieldValues[i].ToString();

    }
    dt.Rows.Add(dr);
    }
    }
    reportViewer1.ProcessingMode = Microsoft.Reporting.WinForms.ProcessingMode.Local;
    this.reportViewer1.LocalReport.ReportPath="C:\\Documents and Settings\\amohiuddin\\My Documents\\Visual Studio 2008\\Projects\\sample reporting application\\sample reporting application\\Report1.rdlc";
    this.reportViewer1.LocalReport.ReportEmbeddedResource = "sample reporting.Report1.rdlc";
    this.reportViewer1.LocalReport.DataSources.Clear();
    reportViewer1.DocumentMapCollapsed = true;
    this.reportViewer1.DataBindings.Clear();

    this.reportViewer1.LocalReport.DataSources.Add(rds);


    this.reportViewer1.Show();

    this.reportViewer1.RefreshReport();
    }
    can someone tell me what i m missing?
    i m programatically building a datatable and populating that datatable with data from a text file.nw i m assigning that datatable to report viewer but report viewer is not showing any data.here is my code
    if (counter != 0)
    {
    for (int j = 0; j < counter-1; j++)
    {
    fieldValues = file.ReadLine().Split(new char[] { '\t' });
    DataRow dr = dt.NewRow();
    for (int i = 0; i < fieldValues.Length; i++)
    {
    dr[i] = fieldValues[i].ToString();

    }
    dt.Rows.Add(dr);
    }
    }
    reportViewer1.ProcessingMode = Microsoft.Reporting.WinForms.ProcessingMode.Local;
    this.reportViewer1.LocalReport.ReportPath="C:\\Documents and Settings\\amohiuddin\\My Documents\\Visual Studio 2008\\Projects\\sample reporting application\\sample reporting application\\Report1.rdlc";
    this.reportViewer1.LocalReport.ReportEmbeddedResource = "sample reporting.Report1.rdlc";
    this.reportViewer1.LocalReport.DataSources.Clear();
    reportViewer1.DocumentMapCollapsed = true;
    this.reportViewer1.DataBindings.Clear();

    this.reportViewer1.LocalReport.DataSources.Add(rds);


    this.reportViewer1.Show();

    this.reportViewer1.RefreshReport();
    }
    can someone tell me what i m missing?
    i m programatically building a datatable and populating that datatable with data from a text file.nw i m assigning that datatable to report viewer but report viewer is not showing any data.here is my code
    if (counter != 0)
    {
    for (int j = 0; j < counter-1; j++)
    {
    fieldValues = file.ReadLine().Split(new char[] { '\t' });
    DataRow dr = dt.NewRow();
    for (int i = 0; i < fieldValues.Length; i++)
    {
    dr[i] = fieldValues[i].ToString();

    }
    dt.Rows.Add(dr);
    }
    }
    reportViewer1.ProcessingMode = Microsoft.Reporting.WinForms.ProcessingMode.Local;
    this.reportViewer1.LocalReport.ReportPath="C:\\Documents and Settings\\amohiuddin\\My Documents\\Visual Studio 2008\\Projects\\sample reporting application\\sample reporting application\\Report1.rdlc";
    this.reportViewer1.LocalReport.ReportEmbeddedResource = "sample reporting.Report1.rdlc";
    this.reportViewer1.LocalReport.DataSources.Clear();
    reportViewer1.DocumentMapCollapsed = true;
    this.reportViewer1.DataBindings.Clear();

    this.reportViewer1.LocalReport.DataSources.Add(rds);


    this.reportViewer1.Show();

    this.reportViewer1.RefreshReport();
    }
    can someone tell me what i m missing?
    i m programatically building a datatable and populating that datatable with data from a text file.nw i m assigning that datatable to report viewer but report viewer is not showing any data.here is my code
    if (counter != 0)
    {
    for (int j = 0; j < counter-1; j++)
    {
    fieldValues = file.ReadLine().Split(new char[] { '\t' });
    DataRow dr = dt.NewRow();
    for (int i = 0; i < fieldValues.Length; i++)
    {
    dr[i] = fieldValues[i].ToString();

    }
    dt.Rows.Add(dr);
    }
    }
    reportViewer1.ProcessingMode = Microsoft.Reporting.WinForms.ProcessingMode.Local;
    this.reportViewer1.LocalReport.ReportPath="C:\\Documents and Settings\\amohiuddin\\My Documents\\Visual Studio 2008\\Projects\\sample reporting application\\sample reporting application\\Report1.rdlc";
    this.reportViewer1.LocalReport.ReportEmbeddedResource = "sample reporting.Report1.rdlc";
    this.reportViewer1.LocalReport.DataSources.Clear();
    reportViewer1.DocumentMapCollapsed = true;
    this.reportViewer1.DataBindings.Clear();

    this.reportViewer1.LocalReport.DataSources.Add(rds);


    this.reportViewer1.Show();

    this.reportViewer1.RefreshReport();
    }
    can someone tell me what i m missing?
        
    i m programatically building a datatable and populating that datatable with data from a text file.nw i m assigning that datatable to report viewer but report viewer is not showing any data.here is my code
    if (counter != 0)
    {
    for (int j = 0; j < counter-1; j++)
    {
    fieldValues = file.ReadLine().Split(new char[] { '\t' });
    DataRow dr = dt.NewRow();
    for (int i = 0; i < fieldValues.Length; i++)
    {
    dr[i] = fieldValues[i].ToString();

    }
    dt.Rows.Add(dr);
    }
    }
    reportViewer1.ProcessingMode = Microsoft.Reporting.WinForms.ProcessingMode.Local;
    this.reportViewer1.LocalReport.ReportPath="C:\\Documents and Settings\\amohiuddin\\My Documents\\Visual Studio 2008\\Projects\\sample reporting application\\sample reporting application\\Report1.rdlc";
    this.reportViewer1.LocalReport.ReportEmbeddedResource = "sample reporting.Report1.rdlc";
    this.reportViewer1.LocalReport.DataSources.Clear();
    reportViewer1.DocumentMapCollapsed = true;
    this.reportViewer1.DataBindings.Clear();

    this.reportViewer1.LocalReport.DataSources.Add(rds);


    this.reportViewer1.Show();

    this.reportViewer1.RefreshReport();
    }
    can someone tell me what i m missing?

    i m programatically building a datatable and populating that datatable with data from a text file.nw i m assigning that datatable to report viewer but report viewer is not showing any data.here is my code
    if (counter != 0)
    {
    for (int j = 0; j < counter-1; j++)
    {
    fieldValues = file.ReadLine().Split(new char[] { '\t' });
    DataRow dr = dt.NewRow();
    for (int i = 0; i < fieldValues.Length; i++)
    {
    dr[i] = fieldValues[i].ToString();

    }
    dt.Rows.Add(dr);
    }
    }
    reportViewer1.ProcessingMode = Microsoft.Reporting.WinForms.ProcessingMode.Local;
    this.reportViewer1.LocalReport.ReportPath="C:\\Documents and Settings\\amohiuddin\\My Documents\\Visual Studio 2008\\Projects\\sample reporting application\\sample reporting application\\Report1.rdlc";
    this.reportViewer1.LocalReport.ReportEmbeddedResource = "sample reporting.Report1.rdlc";
    this.reportViewer1.LocalReport.DataSources.Clear();
    reportViewer1.DocumentMapCollapsed = true;
    this.reportViewer1.DataBindings.Clear();

    this.reportViewer1.LocalReport.DataSources.Add(rds);


    this.reportViewer1.Show();

    this.reportViewer1.RefreshReport();
    }
    can someone tell me what i m missing?

    Monday, December 21, 2009 6:27 AM

Answers

  • Have you done designing to your Report1.rdlc? We need to tell the report which data it should display?

    Please mark the post as Answer/ Helpful, if it helps you.
    • Marked as answer by ali-kanju Monday, December 21, 2009 7:37 AM
    Monday, December 21, 2009 7:08 AM
  • and in the code given "rds" does not seem to be assigned a source. Is it the whole code? or "rds" is assigned a source somewhere..?
    Please mark the post as Answer/ Helpful, if it helps you.
    • Marked as answer by ali-kanju Monday, December 21, 2009 7:37 AM
    Monday, December 21, 2009 7:10 AM

All replies

  • Have you done designing to your Report1.rdlc? We need to tell the report which data it should display?

    Please mark the post as Answer/ Helpful, if it helps you.
    • Marked as answer by ali-kanju Monday, December 21, 2009 7:37 AM
    Monday, December 21, 2009 7:08 AM
  • and in the code given "rds" does not seem to be assigned a source. Is it the whole code? or "rds" is assigned a source somewhere..?
    Please mark the post as Answer/ Helpful, if it helps you.
    • Marked as answer by ali-kanju Monday, December 21, 2009 7:37 AM
    Monday, December 21, 2009 7:10 AM