简体   繁体   English

Crystal Reports使用URL公式生成动态图像

[英]Crystal Reports dynamic image using URL formula

We want to show an image in a Crystal Report 2008 report, and the URL of the image depends on a field in our database, eg: 我们希望在Crystal Report 2008报表中显示图像,图像的URL取决于我们数据库中的字段,例如:

"https://images.somewhere.com/" & {Data.Field} & ".jpg"

This is supposedly possible using a 'picture location' formula on the Picture object ( as described here and suggested here ), but we can't get it to work - it just shows the default picture every time. 据说可以使用Picture对象上的“图片位置”公式( 如此处所述此处所述 ),但我们无法使其工作 - 它只是每次都显示默认图片。

Is there something we are missing? 我们缺少什么?

maybe a bit late! 也许有点晚了! but this is the answer to why you weren't getting pictures (dynamic ones) to show up on crystal report. 但这就是为什么你没有得到照片(动态的)出现在水晶报告上的答案。 The pictures are assembled with the report form (the blank one) on compile time. 在编译时将图片与报告表格(空白表格)组合在一起。 This means when the program code is changed to .exe file that can be run later whatever picture you had then on that form is what is carried over. 这意味着当程序代码更改为.exe文件时,可以在以后运行的任何图片,然后在该表单上运行的是。 No other dynamic pics from urls or from paths. 来自网址或路径的其他动态图片。 Getting pictures dynamically on crystal report is a hustle. 在水晶报告上动态获取图片是一种喧嚣。 Read on things like 阅读类似的内容

  • @Picture crystal reports formula @Picture水晶报告公式
  • How to get Pictures dynamically on crystal reports 如何在水晶报表上动态获取图片
  • How to add Byte() pictures on Crystal Reports 如何在Crystal Reports上添加Byte()图片

Some of these methods might help. 其中一些方法可能有所帮助。

I am still searching on solid way to add pics to the crystal reports on run time. 我仍然在寻找在运行时添加图片到水晶报告的可靠方法。 So far, nothing short of experimentation here. 到目前为止,这里没有任何实验。

Crystal Report 无法使用HTTPS 访问计算机中的图像。

That's true: Crystal can't deal with https. 这是真的:Crystal无法处理https。 Just wanted to add one extra info, which caused some headache to me. 只是想添加一个额外的信息,这让我感到头疼。 Crystal dynamic images from URLs doesn't work if the image is hosted remotely and the machine that is running the report is connected through a Proxy. 如果远程托管映像并且通过代理连接运行报表的计算机,则URL中的Crystal动态映像不起作用。

Maybe Crystal can't access the secure server? 也许Crystal无法访问安全服务器? Do the images show if they are stored on your local machine, ie "C:\\images\\" & {Data.Field} & ".jpg"? 图像是否显示在本地计算机上,即"C:\\images\\" & {Data.Field} & ".jpg"?

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM