SSRS RDL Reports Report Scheduling - c#

I am working on application where reports are scheduled using Web Application build on asp.net C# language [.Net 4.5 framework] . This Application uses a Drop-down to take report parameters a category and a Email Address which is saved in Database.When some user wants a report for particular category then he select category and report is generated using saved database parameters and this report automatically emailed to that email address using web application.Report is generated using ReportViewer ReportViewer.ServerReport.Render(); to convert into excel sheet. Report viewer itself is hidden from users.ReportViewer only used to genrate excel sheet.Problem is if we have 50 mails then application keep running for 5 Hours which is very frustrating.I have heard about ssrs scheduled reports , but how can i set parameters using Web Application GUI also I need a one click send button on Web Application.If the user log out then it is scheduled in database and reports are genrated in queue.Please guide me with correct approach. I hope i am able to make every thing clear.
Thank you.

Related

can windows service be used to generate & print crystal reports?

I have got an application that needs to print reports at a distant location connected via the internet. Since there is no network printer we have to send reports generated through email and wait for someone to print them.
I was thinking if I can use windows service to automate the task
I've got the following options
get data from SQL Server base on filters transferred from distance location to generate crystal report and print it to the default printer.
get the report in pdf format from distance location & print it to the default printer
is any one of the options possible.
I'm asking for some help here since I've not created a windows service up till now for anything
Your guidance is highly applicated
Thanks a lot
Amit Saraf
Yes, your application can use the Crystal runtime and trigger a printout or an export of a report without any display to the screen.
Alternatively, the application can use a command line API of several cheap/free 3rd-party Crystal tools (typically, they are called viewers or schedulers) to achieve the same thing. The command line API would allow you to specify the rpt file, parameters, login info, printer destination, export format, export file, etc.
Yess window services generate and print the crystal report:
Firstly you have install the packages from nuget but you have use VS.
Step 1: Create the Database
Step 2: Create the Window Service
Step 3: Install the Windows Service
Also help from this link:
http://aspalliance.com/1917_Automate_delivery_of_Crystal_Reports_With_a_Windows_Service.3

Replicating a Crystal Report created by an ERP and sending it from server to client

The company I work for has an ERP that generates Crystal Reports using data from the ERP Database (MS SQL Server).
Example: Mitch from sales (who we've purchased a very expensive ERP license for) wants to know how many hammers we have in stock. He goes into the ERP clicks the "Report" button, and a new window pops up with a crystal report showing him how many hammers are in stock.
My boss would like Jeremy (who does not have a very expensive ERP license) to be able to see these reports as well. Jeremy needs to be able to right click an item (e.g. hammer) in our document management software and generate a report from there.
I have spent more hours trying to figure out how to do this than I'd like to admit. I am successfully sending back a string of all the right info based on the selected item, but can't figure out how to get it sent back as a Crystal Report (which is absolutely necessary for some reason which has yet to be explained to me). The report can be in any file format (i.e. ttx, rpt, html) as long as its laid out just like the report generated by the ERP.
Additional info:
I can make Crystal Reports just fine in the Crystal Reports for Visual Studio SDK but can't successfully use an existing report as a template
I have access to everything on the server
My server side code is ASP.NET using C#
The reports are generated from stand-alone rpt files, rpt + vbscript files, and rpt + sql + ttx files
The report I'm currently trying to replicate uses a ttx and sql file to populate the data
The string I'm sending back is obtained using an altered version of the sql query that I've made into a stored procedure
I'm probably missing some crucial info that is needed to answer this question so feel free to ridicule me and ask for whatever you want. That's what my boss does.
thanks #BoldAsLove. In answer to your questions... 1) The goal is to generate the reports server side and send them back to the client (I'm thinking as a pdf or html). I'm trying to get it working on the client first and then transfer it over to the server because our server is running on Windows 7 and I can't figure out how to remote debug a program on that OS. 2) I've tried spinning up a report on my client application several different ways with different results (feel free to ask additional clarifying questions on this. I've been in and out of this project for the last couple of months and my brain is fragmented to the point where I might be saying something stupid or wrong). I can successfully get a report with the right data if I build it from scratch in Visual Studio and set the Data Source in Crystal Database Expert as a DataSet that I make within the project (with column names that match the ones in the ERP database). If I try to generate the report based off of an existing report I either get an error saying
Error in File CrystalReport1
Report GUID
Error in formula Object_Visibility:
formula = (Trim ({Hammer_Report_ttx.HammerID}) = '')
This Field is not known
Details: errorKind
or a login window pops up and I fail to login (and I've used every login credential combo on our server that I can think of).

Downloading SSRS report from report server using C# code

I have been working on a requirement to deploy and download SSRS reports programmatically from C# code.
I used the service exposed by SSRS (ReportingServices2010). I am able to deploy my reports from application server to report server successfully. I referred to "https://www.codeproject.com/Articles/43133/Deploying-Reports-in-Reporting-Services-Programmat" for this.
Meaning, the deployment portion is done and I am able to deploy the report using C# code. But now, I want a functionality to download reports from report server and place it to Application server somewhere. I want to achieve this in similar way, like I did for deploying (using C# code).
But I am unable to find any method exposed by service which can return content of the report deployed on report server.
As a work around I found a way to directly query on Report Server Database or Power shell script as well. But I would prefer a solution using C# code only.
Please suggest if we can download SSRS report from report server programmatically using C# code.
Thanks,
Ketan
You can look at the code for command Out-RsCatalogItem in ReportingServicesTools GitHub project to determine how to download using the SOAP Proxy. In order to create a Web Service Proxy in .NET, look at this page. If you are still not sure how to proceed, then leave a comment and I will try to hack up a quick sample.

Schedule and Send reports automatically using asp.net vb

I want to create a scheduler to email reports automatically in asp.net vb. I will set parameter for report and save it in the database. This report will be send automatically on the scheduled time.
I need some guidelines to start working on it. How will I send it OR how the system will recognize the schedule time and email the report.
If you want to go automatically, you will need to create a window application not asp.net. You can simply add a window application to generate crystal report and send mail.
Now how it will work automatically, you need to create a window task as below any of one links. In that you can give your exe path and give date and time schedule to run this exe.
http://www.makeuseof.com/tag/how-to-automate-windows-programs-on-a-schedule/
http://www.techsupportalert.com/how_to_schedule_programs_to_run_automatically.htm
In asp.net side, this can not do this.
There are free crystal reports schedulers. Why do you need to rediscover the hot water:
http://www.r-tag.com/Pages/CommunityEdition.aspx
http://www.groffautomation.com/

Crystal Report Runtime software from server in C#

advanced hello to all
I made an application in C# , in that app I have some report created with crystal report
is there any way to running this report without installation crystal runtime in clients machine
maybe using crystal report that installed on server ?
thanks
farzad
If you know when and who will need the report you can use a scheduler. There are few vendors who produce schedulers for Crystal reports. The way how it works is : You will choose the report, the parameters , the export type (PDF, Excel, Word, HTML etc.) and the time when the report should be started. The scheduler will run the report, export it and deliver it. Depending on the scheduler you might be able to deliver the exported files to a network drive , e-mail address, SharePoint etc. Her is a link to an article comparing different schedulers:
http://kenhamady.com/cru/comparisons/desktop-scheduling-engines
I don't think there is no way to run a Crystal Report on a computer without installing the client components locally. You could, however, develop a service running on the server machine, which takes a report from a client, renders it to PDF (for example) and sends the results back for displaying on the client. This wouldn't be a simple task though, since you might also have to consider further input from the client (like report parameters, which you can't even determine at runtime without the client components) and have to implement communication over the network.
Otherwise, maybe you are more interested in a web-based approach and need Crystal Reports Server?

Categories

Resources