Without Visual Studio, you can easily implement a report within 5 minutes.
For general report design, such as RDLC and Crystal Reports, Visual Studio must be installed to design reports through the report design interface provided by. NET developers are very convenient, but for non-developers, it is a bit costly to install a 4g vs and require a License. This article provides another method to design reports without using.
With the free report designer (Green exe Executable File) provided by ActiveReports, we can also design reports. The following describes how to design reports:
Who should read this article?
- Report designer
- Product Manager
- Demand Analyst
Necessary Environment
- The. NET Framework 4.0 environment is installed.
- MS Office Access 2007 and later
1st minutes: understanding the report designer
Double-click grapecity.activereports.samples.enduserdesigner.exe. The following report design page is displayed.
SELECT Product. Product ID, product. Product Name, product. Supplier ID, product. Category ID, product. unit quantity, product. unit price, product. Inventory, product. Order Quantity,
Product. reorder quantity, product. Abort, product. Picture, product. Product description, category. category name, category. description AS Category Description, category. image AS category image,
Supplier. company name AS supplier, supplier. Contact Name, supplier. City, supplier. Address
FROM (supplier INNER JOIN
Product ON supplier. Supplier ID = product. Supplier ID) INNER JOIN
Category ON product. Category ID = category. Category ID)
Order by supplier. Supplier ID, product. Category ID DESC
Since then, the data source configuration has been completed, and the introduction to report design has been completed. The following describes the requirements for report design.
3rd minutes: report design requirements
- We want the report to display results similar to the following layout. The report header, report data details, and the end of the report, that is, the overall style is similar to that of the RDLC report.
- You can also display the QR code, Image Display format, report generation time, report page, and other information.
- Considering the lowest cost of system migration in the future, we hope that we can reuse it at the lowest cost in Winform, WPF, ASP. NET, HTML5, and other platforms-one-time well-designed reports.
4th minutes: drag the report Control Design Report
Multiple designer buttons are added at the bottom of the report designer. These buttons can be used to quickly access the layout Wizard to facilitate the design of the report template.
Snap Lines ):Drag a widget on the report design page. When the widget is aligned with other widgets (or the boundary of a report area, an Automatic Alignment Line will appear between the dragged control and the control aligned with it (or the border of a report area), making it easier for users to freely layout the control.
Snap to Grid ):On the report design page, drag a control to automatically align it with the nearest grid line. This function can be enabled or disabled based on settings.
Excel-like auto scrolling ):Drag a widget on the report design interface. When the drag area is beyond the current display range of the design interface, the design interface automatically moves in the direction you drag until the edge of the report design interface.
Pan Mode ):When you switch to the translation mode, a hand-shaped cursor is displayed. You can drag the design page of the report by pressing the left mouse button.
Automatic Dimension lines ):When you drag a widget on the report design page and change the widget size, the widget edge will automatically display a dimension line. You can clearly know the distance between the widget and the report boundary through the dimension line.
Report Control Dialogs dialog box ):You can easily set the attributes of a report control.
By default, the area report layout displays three areas: Header, details, and footer. You can add or delete headers and footers, report headers, and report tails. You can also add 32-level group headers and footers (right-click a report and selectInsertYou can insert the report header, report end, and group header, or group end .). Drag controls to these areas to display report data. The report layout is saved in RPX format.
Drag fields from the data fields to the report, such as the supplier name, contact, address, and city.
For Line, BarCode, and Picture, you need to drag in from the toolbar on the left.
The BarCode and Picture must be modified in the Properties dialog box.Data---DataFieldField.
5th minutes: preview results, print and export
Preview and view the report results as follows:
Export: In the design toolFile---Export-- Multiple file formats (HTML, PDF, Excel, etc.) can be exported ).
PrintFunction. You can use the print button on the toolbar to print the data directly.
How do you think about the impulse to design reports?
Green Report design tool (which can be decompressed, including C # source code)
Database (after downloading the attachment, decompress the file and obtainNWind_CHS_Small.mdbFile)
Online Reference
In addition, the source code is provided for this Green Report designer, which can be customized with your friends, such as adding company logos and other Personalized Requirements. (Install ActiveReports installation authorization for source code compilation)
This article uses the C #. NET green version. If you need the source code of the VB. NET green designer, please leave a message and send it to you separately.
How to display two tables on a report page in visual studio
You can only follow the curve line:
1. First, we need to combine two data tables into a temporary table, and use this table to allocate locations of different tables. It takes time to locate the report.
2. If it is a parent-child table, the relationship is simple. The parent table uses a variable value assignment, and the details are the sub-table content.
-----------------
Merging is a method-based approach. The simplest but troublesome method is to create a temporary table and combine the columns of the two tables into one table. If a field with the same name appears, you need to change it to a different name, and then write a piece of code to append the data of the two data tables to be output to the printer to this table.
In visual studio 2010, how does one add tables and style sheets to the menu bar for easier operations?
Right-click the menu bar and select the style sheet and layout.
It must be noted that it only takes effect in the page design mode.