将具有透明度的图像添加到Crystal Reports

时间:2021-12-23 00:27:02

Is it really true that Crystal Reports does not support images that have transparency?

Crystal Reports是否真的不支持具有透明度的图像?

We are using it at work and the guy that does Crystal Reports told me it doesn't support transparency. I couldn't believe it so I've spent the last 20 minutes googling and think he might be right. This seems absolutely incredible in this day and age.

我们在工作中使用它,而Crystal Reports的人告诉我它不支持透明度。我简直不敢相信,所以我花了最后20分钟谷歌搜索,并认为他可能是对的。在这个时代,这似乎绝对令人难以置信。

Can anyone please confirm whether or not CR supports transparency, and if so how you do it (we are not limited by the type of image to insert - png, gif etc).

任何人都可以确认CR是否支持透明度,如果是这样,你如何做(我们不受插入的图像类型 - png,gif等)的限制。

For the record we are using CR version that comes with VS 2008 (version 10.5).

为了记录,我们使用VS 2008(10.5版)附带的CR版本。

5 个解决方案

#1


CR doesn't support transparency but you can use a wmf image to solve your problem. I'm using CR 12 (2008), i need to put an image as signature (as a watermark) on another image.

CR不支持透明度,但您可以使用wmf图像来解决问题。我正在使用CR 12(2008),我需要将图像作为签名(作为水印)放在另一个图像上。

Example:

Background_image.jpg Signature_image.jpg

Convert Signature_image.jpg into a wmf file using "Inkscape" (freeware).

使用“Inkscape”(免费软件)将Signature_image.jpg转换为wmf文件。

In the report, we have "Background_image.jpg" and over it the "Signature_image.wmf" image, it works great!

在报告中,我们有“Background_image.jpg”,并在其上面写着“Signature_image.wmf”图像,效果很好!

#2


Just reached over here while searching for same problem. Unfortunately this is true till this date :(

刚刚到达这里寻找同样的问题。不幸的是,直到这个日期这是真的:(

Answering this question for users who may visit again here.

为可能再次访问此处的用户回答此问题。

Transparent background of image is not retained when adding it to Crystal Reports

将图像添加到Crystal Reports时,不会保留图像的透明背景

I achived solution following way.

我按照以下方式获得了解决方案。

Painted transperent area with printing page color i.e. white in my case.

绘制的transperent区域,打印页面颜色,在我的情况下是白色。

I would like to put image in page header and some text over it.

我想将图像放在页眉中,并将一些文本放在上面。

In CR design mode.

在CR设计模式下。

  1. right click in page header section -> select section expert
  2. 右键单击页眉部分 - >选择部分专家

  3. select page header -> click insert
  4. 选择页眉 - >单击插入

  5. In page header a check "Underlay following sections" -> click ok.
  6. 在页眉中,选中“Underlay following sections” - >单击“确定”。

  7. back in design, in section "page header a" include image.
  8. 回到设计中,在“页面标题a”部分包含图像。

  9. In section "page header b" include text which I would like to show over image (i.e. I am expecting to be transparent).
  10. 在“页面标题b”部分中包括我想要在图像上显示的文本(即我希望是透明的)。

Hope this helps for future visitors.

希望这有助于未来的访客。

#3


There is another work around I tried and was successful. If you want the image as a watermark in your report, use your report as a sub report in the detail section of the main report and keep the image in a main report page header and use the option 'Underlay Following Sections' in the Section Expert. All the lines and texts will appear properly on top of the image.

我尝试了另一项工作,并取得了成功。如果您希望图像在报告中作为水印,请在主报告的详细信息部分中将报告用作子报告,并将图像保留在主报告页面标题中,并使用“部分专家”中的“底层跟随部分”选项。所有行和文本都将正确显示在图像的顶部。

#4


As AR_Italy said, confirmed that wmf files are the way to go, even though SAP site says transparent images are not supported, so thank you to AR_Italy. The only thing I would add is that these can be Exported from Adobe Illustrator as well (make sure your image has a transparent background first).

正如AR_Italy所说,确认wmf文件是可行的方法,即使SAP网站说不支持透明图像,所以感谢AR_Italy。我要添加的唯一内容是这些也可以从Adobe Illustrator导出(确保您的图像首先具有透明背景)。

#5


If your Image has a white background AND your lazy just check this out: Rightclick on your report, select Report and Report options and Check "Retain Original Image Color Depth

如果您的图片具有白色背景并且您的懒惰只是检查一下:右键单击您的报告,选择报告和报告选项并选中“保留原始图像颜色深度”

#1


CR doesn't support transparency but you can use a wmf image to solve your problem. I'm using CR 12 (2008), i need to put an image as signature (as a watermark) on another image.

CR不支持透明度,但您可以使用wmf图像来解决问题。我正在使用CR 12(2008),我需要将图像作为签名(作为水印)放在另一个图像上。

Example:

Background_image.jpg Signature_image.jpg

Convert Signature_image.jpg into a wmf file using "Inkscape" (freeware).

使用“Inkscape”(免费软件)将Signature_image.jpg转换为wmf文件。

In the report, we have "Background_image.jpg" and over it the "Signature_image.wmf" image, it works great!

在报告中,我们有“Background_image.jpg”,并在其上面写着“Signature_image.wmf”图像,效果很好!

#2


Just reached over here while searching for same problem. Unfortunately this is true till this date :(

刚刚到达这里寻找同样的问题。不幸的是,直到这个日期这是真的:(

Answering this question for users who may visit again here.

为可能再次访问此处的用户回答此问题。

Transparent background of image is not retained when adding it to Crystal Reports

将图像添加到Crystal Reports时,不会保留图像的透明背景

I achived solution following way.

我按照以下方式获得了解决方案。

Painted transperent area with printing page color i.e. white in my case.

绘制的transperent区域,打印页面颜色,在我的情况下是白色。

I would like to put image in page header and some text over it.

我想将图像放在页眉中,并将一些文本放在上面。

In CR design mode.

在CR设计模式下。

  1. right click in page header section -> select section expert
  2. 右键单击页眉部分 - >选择部分专家

  3. select page header -> click insert
  4. 选择页眉 - >单击插入

  5. In page header a check "Underlay following sections" -> click ok.
  6. 在页眉中,选中“Underlay following sections” - >单击“确定”。

  7. back in design, in section "page header a" include image.
  8. 回到设计中,在“页面标题a”部分包含图像。

  9. In section "page header b" include text which I would like to show over image (i.e. I am expecting to be transparent).
  10. 在“页面标题b”部分中包括我想要在图像上显示的文本(即我希望是透明的)。

Hope this helps for future visitors.

希望这有助于未来的访客。

#3


There is another work around I tried and was successful. If you want the image as a watermark in your report, use your report as a sub report in the detail section of the main report and keep the image in a main report page header and use the option 'Underlay Following Sections' in the Section Expert. All the lines and texts will appear properly on top of the image.

我尝试了另一项工作,并取得了成功。如果您希望图像在报告中作为水印,请在主报告的详细信息部分中将报告用作子报告,并将图像保留在主报告页面标题中,并使用“部分专家”中的“底层跟随部分”选项。所有行和文本都将正确显示在图像的顶部。

#4


As AR_Italy said, confirmed that wmf files are the way to go, even though SAP site says transparent images are not supported, so thank you to AR_Italy. The only thing I would add is that these can be Exported from Adobe Illustrator as well (make sure your image has a transparent background first).

正如AR_Italy所说,确认wmf文件是可行的方法,即使SAP网站说不支持透明图像,所以感谢AR_Italy。我要添加的唯一内容是这些也可以从Adobe Illustrator导出(确保您的图像首先具有透明背景)。

#5


If your Image has a white background AND your lazy just check this out: Rightclick on your report, select Report and Report options and Check "Retain Original Image Color Depth

如果您的图片具有白色背景并且您的懒惰只是检查一下:右键单击您的报告,选择报告和报告选项并选中“保留原始图像颜色深度”