Using image resizer in crystal reports - crystal-reports

Anyone know how or why the ImageResizer will not work in crystal reports?
If you paste the URL
xxxx.jpg.ashx?width=50 into a browser, works great.
The exact same path shows nothing when used as a image location in crystal reports (Remove the .ashx?width=50 and it immediately works again). So it's as if the image resizer is unable to execute when called from the crystal reports viewer? (I do not understand why since we have verified that any user, even without being authenticated, can reach the path through a browser)
Crystal Reports 2008, Version 12.2.0.290
In terms of diagnosing the issue, in short involving the image resizer process (by including the .ashx?width=50 on the end of the URL) is the only thing that prevents the image from showing. And this only occurs in crystal. Browsers handle the URL just fine.
UPDATE : Testing without the .ashx also proved to not work. The ?width=50 after .jpg is enough for crystal to just display a blank. (No errors, just no image)
UPDATE : Testing using &format=png or &format=jpg also did not work (Blank in crystal, works perfect in browser)
FINAL UPDATE : We ended up placing the image re-sizer software on a stand alone (what used to be a file manager box) away from our web.config, permissions, and web server and then crystal started rendering the images just fine. So we never really figured out WHY crystal could not render the images when the re-sizer software was loaded on our IIS web server\intranet.....(possibly due to integrated windows authentication turned on even though we granted access to the folder the images were in) ......but it did start working just fine when we bypassed all of that stuff.

I suggest trying an alternate URL syntax to determine if Crystal Reports is simply allergic to query strings.
Try the FolderResizeSyntax plugin "folder/resize(50,50)/image.jpg
Try the CloudFront plugin: "folder/image.jpg;width=50"

FINAL UPDATE : We ended up placing the image re-sizer software on a stand alone (what used to be a file manager box) away from our web.config, permissions, and web server and then crystal started rendering the images just fine. So we never really figured out WHY crystal could not render the images when the re-sizer software was loaded on our IIS web server\intranet.....(possibly due to integrated windows authentication turned on even though we granted access to the folder the images were in) ......but it did start working just fine when we bypassed all of that stuff.

Related

Html2Pdf.exe hangs in TaskManager and pdf generation takes time in hosted server

I'm using Spire.PDF to convert html into pdf.
I have created a .net core 3.1 web application to convert html string into PDF. All working fine on my local machine as well as in the 64 bit server (Hosted in IIS). It just two pages of pdf.
But in the server it always has multiple Html2Pdf.exe in task manager and the converting process is very slow.
I could not find any reason for this. So I requested a trace from IT department when generating the pdf and saw a lot of no successful results. Please take a look at the attached screen shots and advise me what needs to be done to prevent this.

Crystal Reports issue with Dynamic images from a web service

I have a report with two dynamic images defined by database fields.
One is a location on our intranet :
ex: \<folder>\image.JPG
the second is being pulled from a web service :
https:////TraverseImage.ashx?parcel=312531800000010860&card=1
I followed this excellent walkthrough :
http://www.cogniza.com/wordpress/2010/03/15/crystal-reports-dynamic-images/
which suggests "set the formula’s text to the name of the formula or parameter field that will contain the image’s URL"
during design time both images display perfectly. When running the report or when changing parameters, the first one from the hard drive works perfectly, but the second one from the web service does not update. The only way to update it is to delete the image, and start over. I have put a hyperlink on the one from the webservice, and it correctly links to the image I want to display.
I am needing this to stay as a native .rpt and not embedded with VS.
I appreciate any suggestions, or comments.
Mark
Crystal dynamic image paths don't support https. Don't blame me; I'm just the messenger.
But you can solve this by using one of the 3rd-party UFLs listed here.
One of these UFLs allows you to use the graphic location expression for the image in Crystal to on-the-fly download an image from a given url, save it to a local file, and return the path to that file.
As added advantage, it can also resize the image to avoid a known memory consumption issue when Crystal is forced to resize images.
Is the path http or https?
If https you can use a UFL to solve this.

Images are not showing in Crystal Resports 8 in VB6 applications

VB6 application that uses Crystal Reports 8, but images in the reports are not showing.
Images do show fine in our dev environment but in the terminal server win2012 that users access to get to the application, when running a report the images simply do not show.
I have no idea where to start.
You should check the 'real' paths of images in your application when running OUT the IDE.
To test, add a MsgBox that show the paths of images, so you can discover is it's wrong. If paths are corrects, then maybe a users permission problem.
I changed the images on the Oracle database type field for bmp instead of jpg and now they show fine.

Adding link to local file in Confluence

I would like to add a link to a local file in confluence. Obviously this link would only work if the file is locally on the users computer. I understand that.
If I add the address like this :
file:///D:/dev/ngs-frontend/src/pages/myPage.html
The browser sends me to :
about:blank
If I try to add it with quotes like so :
"file:///D:/dev/ngs-frontend/src/pages/myPage.html"
..confluence crashes!
How is it possible in confluence?
As you mentioned when adding the web link in Confluence specifying the file using the file protocol (file:///) you might face the issue that it doesn't work.
Obviously this link would only work if the file is locally on the users computer.
This is not entirely true. If you open the developer tools you most likely will be getting the error "Not allowed to load local resource"
As measure of security the browser won't let you access files from a different origin, specially from the users computer (this would be a serious security risk). Only imagine if you could access the files in the Windows directory from the browser, you could break apart the operating system in no time (or steal user data).
This is explained in here
If you put the file in the same server Confluence is running, then this should work just fine. However I believe you can save time just adding the page as an attachment and loading it (Confluence is pretty decent at version controlling in case you want to modify the html file).
Hope this helps!

Alfresco PDF thumbnail previews unreadable

Not sure this is the right stackexchange site but seems to be the place with the most question about Alfresco I can find so here goes.
Have Alfresco Community Edition 4.2.d installed on a RHEL5 64bit box (mainly default install bar using MySQL as a database locally). Uploading PDFs to the documentLibrary is fine and thumbnail previews and flash previews are generating. If the PDF has been processed by ABBYY OCR (which we have running on a separate server and is used to OCR scanned PDFs) then the flash preview generates fine but the thumbnail is incredibly dark and looks as if it has been attacked by a can of spray paint.
I initially thought it could be a ghostscript issue but have updated that to 9.14 and still getting this issue. I have also tried playing around with ImageMagik but I can't get a nice clear thumbnail to generate. I am guessing it is a switch in the convert command that Alfresco is using but I am struggling to work out a combination of switches that will work and then where Alfresco would store these parameters. Or indeed what switches are currently being used.
I was wondering if anyone had seen this behaviour before with ImageMagik previews in Alfresco 4.2.d? It seems something unique to PDFs that have been through the OCR process so I am guessing I will need to create a separate transformation for them at a later stage.
EDIT: So it was suggested that a later version of ImageMagick and GS should resolve it. I have therefore installed GS 9.14 and IM 6.8.9-0 (both compiled form source). Running the following from a command line:
convert /root/test1.pdf[0] /root/test1.png
results in a crystal clear image thumbnail preview. Thinking I was on to a winner I have amended the following lines in alfresco-global.properties to point to the system location of GS and IM:
img.root=/usr
img.dyn=${img.root}/lib
img.exe=${img.root}/bin/convert
img.gslib = /usr/local/share/ghostscript/9.14/lib/
and alfresco loads. However the thumbnail preview generated by Alfresco using the new version of IM and GS does not result in nice clean previews.
I am guessing that Alfresco is passing some command line switch during the conversion that is undoing the good work of the later versions of these programs. Does anyone know where the switches for thumbnail creation might be stored in Alfresco?
I guess it's related to transparency and default background black. I didn't find an easy way to add the required parameters to the script except to register a new transformer supporting more parameters like:
-fill white -opaque none