Control report programmatically RRS feed

  • Question

  • I first posted to "Reporting" and got no reply, apart from a kind soul who suggested I post to this forum. Keeping fingers crossed!

    I am at the point of creating reports.

    I am using Local processing mode and have been looking for a way to control the report programmatically. So far I have come up with this,

    The only problem is that I still need to create each report in VS2012 and go through the process of creating a dataset, in this case "DataSet1"

    Is there a way to circumvent this?


    Tuesday, September 2, 2014 5:37 AM

All replies

  • There are some additional issues related to the actions taken before I run the code above.

    To create the report I Add New Item to the Project and at some point I get the following picture. The dataset is set to "DataSet1" (see red oval). When I click on "New DataSource" I get the popup form where I select the two tables and at the bottom of the form (red oval) it is prompting AGAIN for Dataset name. I entered "abc". Should this be DataSource name?

    As you can see from the follow up screen below

    In the red oval on the left the Data Source is "abc" and the Dataset is "DataSet1"

    I can only see the fields that belong to one of the tables. If I want to see the fields that belong to the second table I need to right click on DataSet1, select "Dataset Properties" and from Available datasets (red oval on right) I need to select the second table.

    Summarizing I have three questions,

    1) In the Data Source Configuration Wizard popup form (first picture above), should "DataSet name" be "Data Source name"?

    2) Once a Data Source is created (in this case "abc") can I change its name and properties?

    3) Is there a way to include all fields (in the case above all fields from both tables) from all datasets so that I do not need to select the table each time?

    A bit of a mouthful, I know.



    • Edited by JohnPapa05 Wednesday, September 3, 2014 7:42 AM
    Wednesday, September 3, 2014 6:26 AM