We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy.
Unfortunately, activation email could not send to your email. Please try again.

Usage of Report Viewer

Thread ID:

Created:

Updated:

Platform:

Replies:

125623 Aug 29,2016 09:32 AM Aug 30,2016 08:40 AM ASP.NET MVC 1
loading
Tags: ReportViewer
Laurentiu LAZAR
Asked On August 29, 2016 09:32 AM

Hi,

First of all I don't know that only Report Viewer may be concerned by my need.
Anyway what's about: I work on an invoicing module for several applications. I have some questions about how to use all related to reports for my needs.

#1.) By law in my country is required that each invoice to printed in 3 copies, one in blue, one in green and one on red. What attributes of Report may help me to obtain this?
#2.) How can I deal with scenarios when an invoice is longer that one page: I have to print on all pages header and footer but only on first page the number and date of invoice.
#3.) In some scenarios I have to print on same page the invoice and the receipt (when the payment is done with cash it must be issued also a receipt; is not mandatory but customary to print both on same page). I think at this at a kind of conditionally master detail report.
#4.) How can I deal with a kind of conditional invoice based on user that is authenticated in application: let suppose that an user represent an given company and for this reason it must have available only related models of invoice (at first sight I may consider that the information related to company that issued the invoice is pulled from database and all is done, but in reality is not because I need that his invoices are rendered with a specified graphic design, so I consider that must be different report designs)

Regards


Yuvaraj Devarajan [Syncfusion]
Replied On August 30, 2016 08:40 AM

Hi Laurentiu, 

Thanks for contacting Syncfusion support. 

#1.) By law in my country is required that each invoice to printed in 3 copies, one in blue, one in green and one on red. What attributes of Report may help me to obtain this? 
We can achieve your scenario by creating Report Parameter in ReportBuilder and add the available value as Blue, Green and Red. In Report Designer page you can assign the Report Parameter value for the Body, Header and Footer fill color expression property as shown in the following screenshot,     

ReportParameter: 
 

Body Fill Color Property, 
 


#2.) How can I deal with scenarios when an invoice is longer that one page: I have to print on all pages’ header and footer but only on first page the number and date of invoice. 
In Report Builder, we have an option to hide or visible the header and footer content in all pages while printing as shown in the following screenshot,   

Header:                                                                                                                                                                          
 

Footer: 
 

Please refer to the MSDN link for more information, 

#3.) In some scenarios I have to print on same page the invoice and the receipt (when the payment is done with cash it must be issued also a receipt; is not mandatory but customary to print both on same page). I think at this at a kind of conditionally master detail report. 
In ReportBuilder, for Rectangle and Tablix property we have an option to keep the content together on a single page as shown in the following screenshot. When we set this options true the content inside the Rectangle and Tablix are displayed in single page only in the viewer but it won’t work in print layout. If the tablix or the rectangle size is larger than the size of the print paper, then the content of the Tablix will not display in single page.    

Rectangle property: 
 

Tablix Property: 
 

Please refer to the MSDN documentation for more information, 

#4.) How can I deal with a kind of conditional invoice based on user that is authenticated in application: let suppose that an user represent an given company and for this reason it must have available only related models of invoice (at first sight I may consider that the information related to company that issued the invoice is pulled from database and all is done, but in reality is not because I need that his invoices are rendered with a specified graphic design, so I consider that must be different report designs) 
We can achieve your requirement by using query parameter in ReportBuilder. We can filter the DataSource in SQL query or change the look of the report by using the Parameter value in expression dialog of the particular property. For example, if we need to hide the particular column in Tablix based on parameter value as shown in the following screenshot,   

 

Please refer to the MSDN documentation for more information, 


Regards, 
Yuvaraj D. 


CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.

;