VS2010 Report Wizard generates a small example

Source: Internet
Author: User

Vs2010 Report Wizard generates a small example

Environment Description : vs2010 sql2012

Reporting Requirements : According to licno ( license plate number ) field query out Carid , Currentstore , StoreName wait   

information.

First, Database Data Analysis

The report requirement field is from two tables, StoreID for two table primary foreign key join field, in order to facilitate us to create a new view, named "View_carstore" (Building a view is a set of data sets that makes it easy for subsequent reports, and for many relationships a table is best built)

Open the view and look at the data as follows

650) this.width=650; "src=" Http://s3.51cto.com/wyfs02/M00/6B/C4/wKiom1U2P5bxN0FgAACskbV6RYE019.jpg "title=" Image001.jpg "alt=" Wkiom1u2p5bxn0fgaacskbv6rye019.jpg "/>

Second, vs report Design in

1. Create and configure a data source (note that the connection string is in datasource)

650) this.width=650; "src=" Http://s3.51cto.com/wyfs02/M01/6B/C0/wKioL1U2QQqwo8WkAAE_5FMBuvE736.jpg "title=" Image002.png "alt=" Wkiol1u2qqqwo8wkaae_5fmbuve736.jpg "/>

650) this.width=650; "src=" Http://s3.51cto.com/wyfs02/M00/6B/C0/wKioL1U2QWeAkF8KAAF1pHMOEWA573.jpg "title=" Image004.png "alt=" Wkiol1u2qweakf8kaaf1phmoewa573.jpg "/>

2. Create a new report

Here we talk about creating a new report with the Report Wizard, which will automatically generate the dataset

Right-click on "Add"-"added New report", pop-up box directly "Next"

650) this.width=650; "src=" Http://s3.51cto.com/wyfs02/M00/6B/C0/wKioL1U2Qc2DiZ_qAAFadDAY_Do326.jpg "title=" Image006.png "alt=" Wkiol1u2qc2diz_qaafadday_do326.jpg "/>

after determining the data source "next"

After the occurrence, write the query statement

650) this.width=650; "src=" Http://s3.51cto.com/wyfs02/M00/6B/C4/wKiom1U2QJHhe77wAAFNxasBTn0062.jpg "title=" Image008.png "alt=" Wkiom1u2qjhhe77waafnxasbtn0062.jpg "/>

Next Select the rendered style

650) this.width=650; "src=" Http://s3.51cto.com/wyfs02/M01/6B/C0/wKioL1U2QgyRGMrpAAF0IbWVJFE571.jpg "title=" Image010.png "alt=" Wkiol1u2qgyrgmrpaaf0ibwvjfe571.jpg "/>

next, put Licno in the page , meaning that as a query condition, the resulting report will be more than one text box and button.

650) this.width=650; "src=" Http://s3.51cto.com/wyfs02/M01/6B/C4/wKiom1U2QM6xxpb8AAF095dkMJA234.jpg "title=" Image012.png "alt=" Wkiom1u2qm6xxpb8aaf095dkmja234.jpg "/>

Next Select Color,

650) this.width=650; "src=" Http://s3.51cto.com/wyfs02/M02/6B/C0/wKioL1U2QkexhZZeAAHjZOYMj6E668.jpg "title=" Image014.png "alt=" Wkiol1u2qkexhzzeaahjzoymj6e668.jpg "/>

then take the name . Complete

650) this.width=650; "src=" Http://s3.51cto.com/wyfs02/M02/6B/C4/wKiom1U2QQ7B0nFNAAGhkZf2OeY119.jpg "title=" Image016.png "alt=" Wkiom1u2qq7b0nfnaaghkzf2oey119.jpg "/>

At this point the Design tab can be seen

650) this.width=650; "src=" Http://s3.51cto.com/wyfs02/M01/6B/C0/wKioL1U2Qn_xwIzlAACmufcbMTo012.jpg "title=" Image018.jpg "alt=" Wkiol1u2qn_xwizlaacmufcbmto012.jpg "/>

There are parameters inside . Licno is because you have already written the where in the query statement, and you can add parametersin the last Parameters if you do not know the conditions in the query statement when you create a new report .

Preview to see the effect, to the Lic No input car grade

650) this.width=650; "src=" Http://s3.51cto.com/wyfs02/M00/6B/C0/wKioL1U2Qo7jU1EsAAECI9OYJnw354.jpg "title=" Image019.jpg "alt=" Wkiol1u2qo7ju1esaaeci9oyjnw354.jpg "/>

If you need to add another dataset later, you can do so on the left Add the report data, but note that only the RDL file is in design mode and the report data will be available under the View menu .

After you add the appropriate headers and tables to the report, you can drag the fields in the left data set

you can set what the field displays, right-click for example Carid Display content -->expression

650) this.width=650; "src=" Http://s3.51cto.com/wyfs02/M00/6B/C4/wKiom1U2QUCTl9hmAAFKqLV9yH8032.jpg "title=" Image021.png "alt=" Wkiom1u2quctl9hmaafkqlv9yh8032.jpg "/>


This article is from the "8061125" blog, please be sure to keep this source http://8071125.blog.51cto.com/8061125/1636666

VS2010 Report Wizard generates a small example

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.