Error Crystal report hide all Space character - asp.net

I faced an issue like that: When I running source aspx in Local machine and export Report by crystal report, everything look good. but when publish this source to Server, this report export pdf has Hidden all space charracter like this:
All space look like hidden and can see somthing like dot character below each space hidden.
Anyone know this issue please give me a help.
Thanks.
p/s: I using Microsoft visual studio 2008

Check font permissions for user context of the server process.
Also, does the font you use on the server include embeddability permissions?
You can check that via properties of the font.

Open the two reports (the good one and the bad one) in Crystal Designer. Go to File, Page Setup...
Compare the printer assigned. Most likely the bad report is assigned a bad printer (doesn't exist on the server, bad driver, or some other problem).

Related

crystal reports error when hosting on server

I have a web application which I developed which uses crystal reports for VS 2010. The reports work fine on my machine, but when I publish the web application, I get the following error when loading the report:
Error
This group section cannot be printed because its condition field is nonexistent or invalid. Format the section to choose another condition field. Error in File temp_9b46c401-8cdb-45a6-bade-4d3e37dda1fb {572D2B99-425A-4EC5-A758-6497001368A3}.rpt: Invalid group condition.
I've searched for this and from what I can understand it's a connection issue. But I've checked and the database connection string is fine. Other parts of web application work fine with it. Is there anything else I should be checking for?
I've resolved the issue. It was very frustrating and so I thought I should put this here in case anyone runs into this:
Make sure you have the same version of Crystal Reports Runtime installed on your server as on your development machine. I had 13.0.3 on my development machine and 13.0.1. on my server. Of course crystal reports gave an obscure error which makes it very difficult to know where to look.
After I did this, I kept getting a blank page. This linked help me resolve this issue: http://www.codeproject.com/Questions/287543/Crystal-Reports-not-rendering-when-webpage-is-serv. Apparently visual studio doesn't copy all the necessary files for it to render the reports.
Thanks.
I'm not so sure that the error is because of a database connection issue. If I were you I would look into a few things first:
Make sure that the database fields haven't changed. Is the application accessing the same database when deployed as it does in the development environment?
What about Null values? Have you checked the "Convert Database Null Values" in the Report Options?
What about the groups? Are there any formulas in them or are any of them based on groups? Browse the data to see if you get any errors.
Just because it runs on your development machine doesn't mean the problem isn't in the datasource. Maybe one of your report's formulas is expecting a field to be non-null, and there is a single null entry. Or a date somehow got entered as #01/01/9999# and a formula in the report is expecting a realistic date.
That should get you started and maybe even solve your issue. Give us some more info about the report and the datasource if you can.

RadEditor ExportToPDF not generating PDF in client's environment

We are using the Telerik RadEditor control, specifically for it's ability to render a PDF via the ExportToPDF() method on the control. We find that this works great in our development and test environments but fails as soon as we get to our client's environment. What I mean by fails is that typically when you execute the ExportToPDF() method, a dialog box pops up with the name of the PDF file, it's size, and whether you want to open it or save it. In our client's environment that dialog window appears, but the file size does not appear. If you save the file, it's a blank document. The machines / environments are equal in their setup (IIS 6 on Windows server 2003). The only exception is that our client's machine is in a secure environment with no access to the internet.
We are loading form letters into the control and then creating the PDF once the user clicks a button, so I don't think this is being caused by bad data / invalid characters causing the PDF not to generate.
My questions are: does anyone have experience running the ExportToPDF() command in an environment with no access to the internet? Could this be a permissions issue? I can't seem to find documentation on whether the ExportToPDF() functionality uses a temporary directory to write the PDF out to while it's rendering. It may be as simple as that, but I'm having a hard time researching this issue.
I've also put a try / catch block around the ExportToPDF() method and I know it's not throwing any errors.
We are running an older version of RadEditor - 2009.3.1208 - it runs in a large application with other Telerik tools so upgrading the entire RadControl suite is not trivial (b/c of testing, etc) and is taking some time.
Any suggestions on what to try next / has anyone encountered anything like this with this control?
Thanks for your help in advance!
Richard
I doubt that the export functionality needs an active internet connection. Most likely something in your secured environment is blocking silently the export and it does not simply happen. My recommendation is to check the permissions/processes you have on the user machine and test the same outside of the local environment to compare the results.

What installs ReportViewerControl.axd?

Okay, time for a stupid question.
When viewing the browser source code of a ssrs report there is a script tag that references Reserved.ReportViewerControl.axd. There is a query string parameter of the version. What installed component on the web server determines that version #? The reason I ask is I am trying to debug a situation where an installation of our web app (asp.net 3.5) cannot print a report ("Unable to load client control..."), but on our internal machines, we can. I do not have direct access to the web server/db server. I can confirm that I can print directly from the Report Manager. I am trying to piece together any differences b/t the two environments, and one thing I am noticing is the different version query string value.
Our internal says -
Reserved.ReportViewerWebControl.axd?OpType=Resource&Version=9.0.30729.4402&Name=Microsoft.Reporting.WebForms.Scripts.ReportViewer.js"
Client says -
Reserved.ReportViewerWebControl.axd?OpType=Resource&Version=9.0.30729.1&Name=Microsoft.Reporting.WebForms.Scripts.ReportViewer.js"
I am fairly sure it is the Microsoft Report Viewer Redistributable, but I want to make absolute sure. Anyone out there know?
This depends on whether you're using the .NET ReportViewer control on a custom ASP.NET page or whether you're simply using Reporting Services' out-of-the-box viewer. If it is the former, then most likely it's from the Report Viewer Redistributable. If it is the latter, it's from the SQL Server installation.
See if this SO post helps you with your print issue:
ReportViewer Client Print Control "Unable to load client print control"?

Classic ASP on IIS7: ADODB.Stream error File could not be opened - accessing outside the webroot

I've just reinstalled a server, it is a new machine, same OS verion (Win2008) and same IIS version (7.0). The app was working perfectly (and then the machine blew up).
I'm getting this error when I try to access a file outside the webroot:
ADODB.Stream error '800a0bba' File could not be opened
I can access it fine using FileSystemObject, but cannot open it with ADODB.Stream.
Also, I can create a PDF using abcPDF, but I cannot create one again with the same name and overwrite it (this used to work). This works fine inside the website folder structure but not outside.
Also, I cannot attach a file using JMail any more. This applies to files BOTH inside and outside the webroot. So that is weird.
I've assigned Full Control to Everyone on the whole drive to isolate whether it is a permissions problem and it made no difference.
Any ideas anyone?
UPDATE: The problem with attaching files inside the site does not appear to be happening any more, since I mucked round with several things. I'm not sure what did it unfortunately. I got nowhere on this and lost hours over it, so I ended up move all the files inside the webroot and now everything works. This is not ideal and I would still like to get to the bottom of it, but the workaround is acceptable.
Updated question as I accidentally wrote Win2003 instead of 2008.
I think you should check the from your database in the first place how you save the PDF file in question. That is where you saved the file in question into the database from the same machine or from a remote machine. Usually when you save from the same developer machine and you are accessing there will be no error but when the file was saved from a machine other than the developer machine, then you will have such error.
For example:
'1. dbSignatureImage = New ADODB.Stream
'2. dbSignatureImage.Type = ADODB.StreamTypeEnum.adTypeBinary
'3. dbSignatureImage.Open()
'4. dbSignatureImage.
LoadFromFile(dbRecordSet.Fields("client_signature_filename").Value)
From the above code, I was trying to display two different images from the database (one at a time) and among the two images I saved one directly from the developer machine and the other image was saved from a different PC over my network. Whenever I try displaying the second image which was saved from a network PC, then I have the error of file could not be opened. Now what I did was commenting the 4th line and the error seized but then the image was not displaying so I tried displaying the image itself directly from the BLOB field using IO.MemoryStream with the following codes and it is working fine for both the developer machine and any PC over the network.
Dim PassportImageArray() As Byte = CType(dbRecordSet.Fields("client_passport_image").Value, Byte())
Dim SignatureImageArray() As Byte = CType(dbRecordSet.Fields("client_signature_image").Value, Byte())
Dim PassportImageMemoryStream As New MemoryStream(PassportImageArray)
Dim SignatureImageMemoryStream As New MemoryStream(SignatureImageArray)
With picSearchPhotograph
.Image = Image.FromStream(PassportImageMemoryStream)
.SizeMode = PictureBoxSizeMode.StretchImage
.BorderStyle = BorderStyle.None
End With
I think you can go round your problem with this my small idea. I hope it will you some how.
Kasapa-Sunyani
You probably need to take a closer look at the security permissions on the folders outside of your applications home folder. Also take a look at the what user identity is actually used to run your code, for example do you have windows integrated security turned on? If not, is that true of the previous server?
It might help if we could know for sure whether this really is an IIS7 question in which case your server is 2008 not 2003. You might also find that this sort of thing is best handled by the serverfault.com people.
The problem with attaching files inside the site does not appear to be happening any more, since I mucked round with several things. I'm not sure what did it unfortunately. I got nowhere on this and lost hours over it, so I ended up move all the files inside the webroot and now everything works. This is not ideal and I would still like to get to the bottom of it, but the workaround is acceptable.

Why does Visual Studio 2005/2008 keep 'forgetting' to color code and format?

Does any else have a problem where when using VS2005 or VS2008, it suddenly 'forgets' to color code and format the text for you? All of a sudden it acts like its a plain old notepad editor. Sometimes if I save and re-open the file, or else re-start Visual studio altogether, it suddenly 'remembers'. I thought maybe this was because of a bad install on my machine, but recently upgraded to a new one, brand new fresh install with all service packs - and we are right back to the erratic behaviour....
Is this a known problem? Is there a workaround (i.e. a key combo I can hit to tell it to do its thing?)
PS: This happens for me when doing asp.net with VB code - not sure if it affects other flavors of the tool...
EDIT: This is a clean install of VS2008 on Vista, but also have had it on XP. No addins on either setup, problem happens routinely.
Sometimes something similar to this happens to me in VB.Net. In my case it has alway been the backgroundcompiler service that has stopped working for one reason or another. Haven't found anything that helps besides restarting visual studio.
I got this often when working on large web projects (> 1K pages and 4K total files) and most often on ashx files.
At the same time, I would lose intellisense, This was happening because the files I was adding were not getting marked as "Compile" in the file properties -> build option.
I never found the cause (assumed it was overburdening the solution) but I found that it would stay fixed for longer if I deleted the SUO file periodically (it was getting into the 1MB range).
Since coming to a new company, new PC, etc, I have not had this problem but then again I'm not working on as large of a web project.
I use C# in VS2008, and haven't had any problems. Maybe this is VB.NET related?
I used to see the problem with "Web Sites". I have since changed most of my projects to "Web Applications" and haven't seen the issue in a while.
I had a similar issue with VS 2003. I use VS 2008 right now and this doesn't happen anymore.

Resources