Results 1 to 5 of 5

Thread: Proble with Dataset passin in a RDLC Report in Visual Basic

Hybrid View

  1. #1

    Thread Starter
    Member
    Join Date
    Jun 2016
    Posts
    39

    Proble with Dataset passin in a RDLC Report in Visual Basic

    Hi again,
    I am here one more time to solve a strange problem i am facing....
    I am developing a project, and at this point i design the reports...
    In a windows form i put a Report Viewer, in which i associate
    a RDLC Report file.
    In the form i am preparing a Dataset who contains a Table
    When finish the prparation of the Dataset, i am assign the
    Datasource for the Report as follow :

    Code:
    With Me.ReportViewer1.LocalReport
                .DataSources.Clear()
                .DataSources.Add(New Microsoft.Reporting.WinForms.ReportDataSource("EveryVehicle1", ReportDataSet.Tables("Report")))
            End With
    the Data set i have prepare is the ReportDataSet
    After that, i have Add a new Dataset in my project, named "Every_VehicleDataset.xsd"
    There i add a Table named "EveryVehicle1" containg the same things as "Report" Table.

    After that i add to the RDLC File a Dataset following thw wizard and choosing the table from "Every_VehicleDataset.xsd"
    I named that Dataset as "EveryVehicle1"

    After that, i add the fields of the Dataset in a Tablix in the Report File,
    and i run my project!

    Everything is fine, exept one column of the Table, that is not show data at all!
    I have the column, I have the Header, but no Data

    Here is a picture with empty column...

    Name:  Empty_column.jpg
Views: 877
Size:  33.9 KB


    Any one can help me?

  2. #2
    King of sapila
    Join Date
    Oct 2006
    Location
    Greece
    Posts
    6,597

    Re: Proble with Dataset passin in a RDLC Report in Visual Basic

    Σπερααα.
    Haven't used windows reports, just Crystal but 3 options:
    Check that the report you create has the this column included (i guess it does, as seen from your picture)
    Check that the datatable contains that column and that column brings back data. (somtehing like a ?DataqsetX.DataTable(0)("columnname").ItemArray.Count).
    Check that you are in the correct format on the column. Meaning the datatable may have a double and you are trying to convert to datetime. Check the formatting.
    ἄνδρα μοι ἔννεπε, μοῦσα, πολύτροπον, ὃς μάλα πολλὰ
    πλάγχθη, ἐπεὶ Τροίης ἱερὸν πτολίεθρον ἔπερσεν·

  3. #3

    Thread Starter
    Member
    Join Date
    Jun 2016
    Posts
    39

    Re: Proble with Dataset passin in a RDLC Report in Visual Basic

    Quote Originally Posted by sapator View Post
    Σπερααα.
    Haven't used windows reports, just Crystal but 3 options:
    Check that the report you create has the this column included (i guess it does, as seen from your picture)
    Check that the datatable contains that column and that column brings back data. (somtehing like a ?DataqsetX.DataTable(0)("columnname").ItemArray.Count).
    Check that you are in the correct format on the column. Meaning the datatable may have a double and you are trying to convert to datetime. Check the formatting.

    Καλημέρα!
    Every thing you say, i have checked them and its ok all!
    The problem is remaining!

  4. #4
    King of sapila
    Join Date
    Oct 2006
    Location
    Greece
    Posts
    6,597

    Re: Proble with Dataset passin in a RDLC Report in Visual Basic

    Does ReportViewer have a .DataSources.Update() and .DataSources.Refresh() ?
    If so, try using these options after .Clear , μαζί, χωριστά κλπ.
    ἄνδρα μοι ἔννεπε, μοῦσα, πολύτροπον, ὃς μάλα πολλὰ
    πλάγχθη, ἐπεὶ Τροίης ἱερὸν πτολίεθρον ἔπερσεν·

  5. #5

    Thread Starter
    Member
    Join Date
    Jun 2016
    Posts
    39

    Re: Proble with Dataset passin in a RDLC Report in Visual Basic

    Οκ,
    What you say i have not try them.
    I will and i will let you know!
    Thanks again!

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width