水晶报告到adobe PDF - 字体问题 [英] Crystal report to adobe PDF - font issue

查看:97
本文介绍了水晶报告到adobe PDF - 字体问题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我徒劳无功地搜索了几个月,但仍然没有找到其他人。类似问题的解决方案对我不起作用或者根本不适用。



我有一个用Visual Studio.Net 2012编写的Web应用程序(C#/ ASP。净)。应用程序从Oracle表中提取一小组数据,然后使用Crystal Reports将该数据抛出到Adobe Acrobat在浏览器中显示的报表页面上。然后,用户将单个Adobe Acrobat页面打印为优惠券,并将其物理扫描到我们的文档扫描系统中。这个文档扫描系统需要一个特定的字体,这里是问题...目前,该应用程序正在我们的生产环境和我们的用户验收测试(UATest)环境中运行。 Adobe Acrobat页面为每个Web环境显示不同的字体集。在UATest上,一切都在显示。字体是OCR A Extended。它是一种等宽字体,类似于旧的Courier风格。在我们的生产系统中,它显示的是Arial?微软Sans Serif?我不知道,但无论如何,我们的扫描系统都不喜欢它,也不会接受它。



情况就是这样。此时我无法改变河流。这意味着我坚持使用当前的方法。自动化流程以便数据从网站进入扫描仪上的数据表是理想的,但这是不可能的。



此时,我已经得到了从UATest服务器运行应用程序的用户。不是最理想的解决方案,但它必须坚持到我找到解决方案。



任何人都可以给我的任何帮助将不胜感激。



我的尝试:



这是技术性的东西......



*这两个Web服务器都是Windows Server 2012 / R2。



* IIS设置完全相同对于两个Web服务器上的两个应用程序。



*我已同步两个Web服务器上的所有字体和字体设置。它们与两台机器上的字体数字和文件完全相同。



*应用程序是我们部门内部的,并且通过Active Directory控制对它的访问。不确定这是否重要,但更好的是有太多的信息而不是不够。



*应用程序是相同的,这意味着我复制了整个应用程序从UATest机器上显示正确字体的文件夹到生产机器上它没有。



*字体设置正确并在Crystal中正确显示在开发机器上报告创建者(我的本地机器用于编码,编译和部署应用程序)。



*无论使用何种浏览器,结果都是相同的。



*我已经进入水晶报告,右键单击 - >设计 - >默认设置 - >字体标签。然后为每个可能的对象将默认字体设置为OCR A Extended。

I've searched in vain, off and on for several months, and still haven't found anyone else with this issue. Resolutions to similar issues aren't working for me or simply don't apply.

I have a web application written in Visual Studio.Net 2012 (C#/ASP.Net). The application pulls a small set of data from an Oracle table, and then uses Crystal Reports to throw that data onto a report page that is displayed by Adobe Acrobat within the browser. The Users then print out the individual Adobe Acrobat page as a 'coupon', and physically scans it into our document scanning system. This document scanning system DEMANDS a particular font, and here's the issue...Currently, the app is running in our production environment, and our User Acceptance Testing (UATest) environment. The Adobe Acrobat page is displaying a different font set for each web environment. On UATest, everything is displaying as it should. The font is OCR A Extended. It's a monospaced font that resembles the old Courier style. On our production system, it's displaying what looks like Arial? Microsoft Sans Serif? I have no idea, but whatever it is, our scanning system doesn't like it and won't accept it.

The situation is what it is. I can't alter the river flow at this point. That means I'm stuck with the current methodology. Automating the process so that the data goes from website into the data tables on scanner would be ideal, but that's not possible.

At this point, I've got my Users running the app from the UATest server. Not the most ideal solution, but it will have to hold until I find the fix for this.

Any help that anyone can give me would be greatly appreciated.

What I have tried:

Here's the technical stuff...

* The two web servers are both Windows Server 2012/R2.

* The IIS setup is identical for both applications on both web servers.

* I've synchronized all of the fonts and font settings on both web servers. They are exactly the same number and files for fonts on both machines.

* The application is internal to our department, and access to it is controlled through Active Directory. Not sure if that matters for this, but better to have too much info than not enough.

* The applications are identical, meaning that I've copied the entire application folder from the UATest machine where it displays the proper font, onto the Production machine where it doesn't.

* The font is set correctly and shows correctly in the Crystal Report creator on the development machine (my local machine used to code, compile, and deploy the app).

* The results are the same regardless of the browser used.

* I've gone into the Crystal Report, Right Clicked -> Design -> Default Settings -> Fonts Tab. And then set the default fonts to OCR A Extended for each possible object.

推荐答案

如评论中所述,在Windows服务器上安装新字体通常需要重新启动。



如果没有重启,只会向当前会话通知新字体。其他会话(如ASP.NET)未通知,也无法使用新字体。



有时可以通过调用 AddFontResource 来避免重启[ ^ ]来自内部执行的代码目标会话。但根据我的经验,您仍然需要至少重新启动IIS才能获取更改。
As discussed in the comments, installing new fonts on a Windows server typically requires a restart.

Without a restart, only the current session is notified of the new font. Other sessions, such as ASP.NET, are not notified, and will not be able to use the new font.

It is sometimes possible to avoid a restart by calling AddFontResource[^] from code executing within the target session. But in my experience, you still need to at least restart IIS for the changes to get picked up.


这篇关于水晶报告到adobe PDF - 字体问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆