I have reports in reporting services. I want to add an introductory page to the report that shows a logo, report name , date and a few other details. However, I want to show that page only when user prints the report. Is this possible and if yes how?
If I run the package from Visual Studio, it works; If I deploy it and execute it, it works; If I log in the server an execute it, it works; If I execute it from a Task using the SQL Server Agent it works fine until I have a DataReader Source in the Package!
Is there a way to display messages? To see more details why it is not running?
I have a report that is grouped based on a field. There is no way to pre-determine the number of detail lines each group will have. Is there a way to set the print condition such that if any group details do not fit onto one page then the whole group should be printed on the next page. Something like this:
If ALL Group2 details do not fit onto the same page print it on a new page. (I don't want each group on a separate page, I just want the group detail to start on a new page IF THEY DO NOT ALL fit on one page)
So I have been asked by our sustainability person to create report from our printing data that actually shows the number of pieces of paper used. This is easy enough for single-sided printing, but when printing in duplex the software does not take into account that 3 printing pages actually equates to 2 pieces of paper. I know this sounds simple, but say I have a print job record that looks like this:
This is a print jobs that if done correctly is actually 21 pages( duplex printing). If the job is say total_pages =5 I cant just divide by 2 because its actually using 3 pieces of paper ( yes they are wanting this data don't ask why). How can I adjust some sql to accurately depict 5 pages, front and back, as 3 pieces of paper?
I have deployed a report that is configured for landscape printing. It does print in landscape, however, only the first seven columns appear on the first page and the other five columns appear on the next page. Is there a method, like in print preview setup in MS Excel, where we can scale down the print (like to 80%) so all columns appear on each page?
Well I made a bussiness object for registering users as well as logging them in. I dont know if my bussiness obect is screwed up or if its the database, or the SQL syntax or what. Please take a look at this. I am not getting any error messages, but nothing is being added to the server. I am using MSDE for the SQL Server.
Here's my bussiness object:
Imports System Imports System.Data imports System.Data.oledb
NameSpace LoveShare
Public Class UserDetails public UserID AS Integer public FirstName AS String public LastName AS String public UserName AS string public Password AS String public Address AS String public City AS String public State AS String public Zip As Integer public Email AS String End Class
Public Class User
Private objConn As New oledbConnection("Provider=sqloledb;Data Source=GARAGESALELOVESHARE;Initial Catalog=LoveShare1;User Id=sa;Password=notonthispost;")
Public function Login(strUsername AS String, strPassword As String) As Integer dim intID as integer dim objparam AS new oledbparameter dim objcmd AS oledbCommand
objCmd = new oledbCommand("dbo.SPLoginUser", objconn) objcmd.commandtype = commandtype.Storedprocedure
objparam = New oledbparameter("@UserName", oledbtype.Char) objParam.Value = strUserName objCmd.Parameters.Add(objParam)
objParam = New oledbParameter("@Password", OleDbType.Char) objParam.Value = strPassword objCmd.Parameters.Add(ObjParam)
Try objConn.Open intID = CType(objCmd.ExecuteScalar, Integer) objConn.Close Catch e As Exception Throw e End Try
If intID.toString = "" Then return 0 End if Return intID end function
Public Sub AddUser(objUser As UserDetails) Dim intId as integer Dim objReader As oledbdataReader Dim objCmdID As New oledbCommand("SELECT MAX(userID) FROM tblUsers", objconn) Dim objcmd AS New oleDBCommand("spAddUser", objConn) Dim objparam AS OleDbParameter objCmd.CommandType = CommandType.StoredProcedure
objParam = New oleDbParameter("@FirstName", oledbtype.Char) objParam.value = objuser.FirstName objCmd.Parameters.add(objParam)
objParam = New oleDbParameter("@LastName", oledbtype.Char) objParam.value = objuser.LastName objCmd.Parameters.add(objParam)
objParam = new oleDbParameter("@UserName", oledbtype.Char) objParam.Value = objUser.UserName objCmd.Parameters.Add(objParam)
objParam = New oleDbParameter("@Password", oledbtype.Char) objParam.value = objuser.Password objCmd.Parameters.add(objParam)
objParam = New oleDbParameter("@Email", oledbtype.Char) objParam.value = objuser.Email objCmd.Parameters.add(objParam)
objParam = New oleDbParameter("@Address", oledbtype.Char) objParam.value = objuser.Address objCmd.Parameters.add(objParam)
objParam = New oleDbParameter("@City", oledbtype.Char) objParam.value = objuser.City objCmd.Parameters.add(objParam)
objParam = New oleDbParameter("@State", oledbtype.Char) objParam.value = objuser.State objCmd.Parameters.add(objParam)
objParam = New oleDbParameter("@Zip", oledbtype.Integer) objParam.value = objuser.Zip objCmd.Parameters.add(objParam)
Try objConn.Open ObjCmd.ExecuteNonQuery objUser.UserID = CType(objCmdID.ExecuteScalar, Integer) objConn.Close Catch e AS Exception Throw e End try
If objUser.UserID.ToString = "" then objuser.UserID = 25 End if End Sub End Class End NameSpace
Here's is my stored procedure for the registration:
Session("UserID") = objUserDetails.UserID FormsAuthentication.SetAuthCookie(objUserDetails.UserID, false) Response.Redirect("index.aspx") else lblMessage.text="Information entered incorrectly" End If End Sub
I have a database which has contact column eg. Mr Peter Smith
I am writing a new database which is to have three seperate columns.. saluation, first name and surname. What would be the best way to split the column up?? I was thinking on concentrating on the spaces??
Note: some conacts may not have saluation inc in the contact column, and in this case the saluation column should be blank...
Can somebody please go in depth detail what exactly is done in OLAP? i know it deals with the data warehouse end. but what does the SQL DBA do in the OLAP end? please elaborate. thanks.
How can i get the details of the error in sql server 2000 such where itoccurs in which line. I need something like i get in sql query analyzer.--Message posted via http://www.sqlmonster.com
Where is, (or even does it exists) the best place to look for some details on when package execution fails if running as a scheduled job. Obviously when you run from the command line or in VS, there is plenty of output detail on progress and on the source of errors, but when you run it as a scheduled job, it just says step 1 failed in the sql server log, and package foo failed in the NT application log . Is there anywhere to find this info or do we need to build error traps into the package to write stuff out somewhere?
I am developing an applicaiton through which, i want to print from pocket pc emulator 2003. I am using PrinterCE.NETCF SDK to do this task. I am able to print from my applicaiton like we do in ASP (Printing one line at a time). In PrinterCE, there is an option of printing the output to a file. But, I am not able to find how we do it.
So, I want to know how we can print the output through PrinterCe into a file. Can anybody help me??
Hey all, I'm new to SQL and am having some troubles w/ a problem I was given. I have two tables (OrderTableA & OrderTableB) which are linked by an OrderID. What I need to do is have the two tables printed out to two txt files. Below is the code I have so far.
SELECT OrderID, "#" + OrderDate AS OrderDate, "&" + CustomerID AS CustomerID, Total FROM OrderTableA;
SELECT OrderID, Quantity, Discount, UnitPrice FROM OrderTableB;
The txt file for OrderTableA has to look like this: !!OrderID OrderDate CustomerID Total ---------- ----------- ----------- ------ 123456 #123456 &123456 123456
with the !! before OrderID in the header, the # before OrderID in the table and the & before the CustomerID in the table.
I'm not sure my code above is correct so far, and I've no idea how to print this to two txt files.
Any help would be greatly appreciated!! Thank you!
I have a report with two columns. It works fine in SQL Reporting Services, but when I push it to the Report Server it only prints one column instead of the two that it's set up to print.
Hi i'm having a problem in printing a reporting services report. Between each page it's giving me a white paper. What can i do in order not to get the white papers anymore? Any help?
I have a script or SP that takes a very long time to performmultiple tasks, and after each one there is a PRINT statementthat shows the time and what was just accomplished, to help memonitor what's happening and estimate how long it will take.In a script, I can put a GO after each PRINT to cause the outputto appear immediately, but that's not possible inside an SP.Instead, it seems the output goes to a buffer, and the bufferis only output when a PRINT causes the buffer to become full.Sometimes there is a long delay before the buffer fills. Isthere a way other than GO to cause immediate printing? (Iguess I could just use longer messages, and fill up thebuffer with every one, but that's not very elegant.)Thanks,Jim GCountrywide Home Loans
Hi! I recently begin to use reporting tools of SLQ 2005 instead of AR or CR. I found the DUI very easy to use and I'm partially sastify beause when I try to print my report, the printer always blow out a second white page. For one page report I can live with that but for 156 page report it's becoming a lot annoing. Is there somebody who experience the same problem? And by the way resolve it?
Here the dexcription of the report:
Is a list grouped by clientId with a sub report getting the clientId from the parent one as the parameter. Event with the insert page break after list true or false the result is the same while printing.
I have created a blank report in VS 2005. I set the pagesize to 21cm x 29,7cm (A4) and margins to 1cm. Body size is 19cm x 27,7cm. I set the body border to 1pt. When I print this blank report I won't get printed as I expcted. The printed margins are very different from the margins which I set. Hos can I solve this problem?
We are displaying the reports in Web Application using Report Viewer control.When we run the report and want to take printout we are clicking on Print button of Report Viewer then it is giving error "Unable to Load Print control" Install some activex control.
With out this error how can we print the report. How to overcome this waring.
We have created reports with page size width : 11in and height : 8.5in so that we get pages printed in the landscape mode. We use HP LaserJet 3500 and reports were printing correctly in landscape format. Everything was working fine till we introduced a new printer Dell 1110 laser printer to the environment.
When we have our Dell 1110 laser printers set as default, the page setup IS NOT set to landscape and when I manually change it to landscape, it prints in a compressed portrait image rather than landscape.
However when the HP LaserJet 3500 is set as the default, it prints correctly in landscape.
As the client is using Dell 1110 laser printers i need to fix this issue immediately. Can someone guide me in resolving this issue..
Is there a way to save print settings with the report so that settings such as the size of paper (A4, legal...) and layout (landscape, portrait) do not have to be specified by user everytime she wishes to print the report?
For some odd reason the footer of my report never gets printed. The footer contains the page number and report name and is very important to my report. I made sure the margins are 1 inches for all sides, made sure Footers printing in first and last pages are checked in the properties section, and gave it a large amount of space around the textbox. Is there anything I am doing wrong? Also, the header and body prints correctly.
i have used report viewer control in my win app, (c#, .net 2.0) and from msql i get data, fill necessary tableadapters and print report. Everything works fine on my computer, i generate report from template, push Print button in report viewer, Print dialog appears and i print the report by clicking OK.
The problem occurs in another computer, where i launch my app, i generate report, push Print button, and when appears print dialog happen strange things:
1. In print dialog i push "Print" button once, and nothing happens, Print dialog is still on top, then i push second time Print and then i can see that to pages is sended to printer (but my report is only one page). Printer does nothing, in printer schedulles there is no jobs.
2. So i press Print button in report viewer second time, Print dialog appears again, i click Print button nothing happens, then i push second time Print button i can see that 1 page is sended to printer, Print dialog disapear and now printer print my report correctly.
and this mesh is everytime i generate report and want to print it. Printer is installed correctly, i tried newest drivers for it. For example with ms office word everything works fine.
Could it be report viewer bug? what are the ways to find out what is wrong?