解决ASP.NE页面水晶报表不显示工具栏图标的问题
2014-06-04 15:07
686 查看
开发环境 :VS2008 ,Crystal Report 2008
开发的网站没有使用系统默认的wwwroot目录,而是另建了一个目录 D:\published 做为网站的目录。
用Crystal Report2008在VS2008中开发报表,显示 正常,但当发布到网站上时水晶报表页没有图片,显示如下图,但是工作正常。
![](http://images.cnblogs.com/cnblogs_com/wsdj-ittech/2010Y/2010Y5M/1.png)
于是找原因,分析网页源码,找到代码如下:
<table cellspacing=0 cellpadding=0><tr nowrap>
<td nowrap width=8> </td><td nowrap width=22px><input type="image" name="CrystalReportViewer1$ctl02$ctl00" disabled="disabled" title="Export" src="/aspnet_client/system_web/2_0_50727/CrystalReportWebFormViewer4/images/toolbar/export.gif" onmouseover="this.src='/aspnet_client/system_web/2_0_50727/CrystalReportWebFormViewer4/images/toolbar/export_over.gif'" onmouseout="this.src='/aspnet_client/system_web/2_0_50727/CrystalReportWebFormViewer4/images/toolbar/export.gif'" style="height:22px;width:22px;border-width:0px;" /></td>
<td nowrap width=8> </td><td nowrap width=22px><input type="image" name="CrystalReportViewer1$ctl02$ctl01" disabled="disabled" title="Print" src="/aspnet_client/system_web/2_0_50727/CrystalReportWebFormViewer4/images/toolbar/print.gif" onmouseover="this.src='/aspnet_client/system_web/2_0_50727/CrystalReportWebFormViewer4/images/toolbar/print_over.gif'" onmouseout="this.src='/aspnet_client/system_web/2_0_50727/CrystalReportWebFormViewer4/images/toolbar/print.gif'" style="height:22px;width:22px;border-width:0px;" /></td>
<td nowrap width=8> </td><td nowrap width=22px><input type="image" name="CrystalReportViewer1$ctl02$ctl03" disabled="disabled" title="Show/Hide Group Tree" src="/aspnet_client/system_web/2_0_50727/CrystalReportWebFormViewer4/images/toolbar/grouptree.gif" onmouseover="this.src='/aspnet_client/system_web/2_0_50727/CrystalReportWebFormViewer4/images/toolbar/grouptree_over.gif'" onmouseout="this.src='/aspnet_client/system_web/2_0_50727/CrystalReportWebFormViewer4/images/toolbar/grouptree.gif'" style="height:22px;width:22px;border-width:0px;" /></td>
根据源码,估计是因为网站没有找到图片资源所致,于是回到网站发布 目录,发现目录下的确并没有"/aspnet_client/system_web/2_0_50727/CrystalReportWebFormViewer4/images/toolbar/export.gif”等等资源
网上有一说:IIS下没有此类资源的原因是: 没有安装 Crystal Report Web Service,或者没有在IIS中注册。
针对此类情况,通常的解决办法 是:
![](http://images.cnblogs.com/OutliningIndicators/ExpandedBlockStart.gif)
安装 Crystal Report Web Service:通过VS.NET安装,自动注册。
注册:首先进入MSDOS方式(可通过“开始”-“运行...”,键入cmd,回车)。
将 C:\WINDOWS\Microsoft.NET\Framework\v1.0.3705 作为当前目录,其中 C:\WINDOWS 根据操作系统的安装位置决定,v1.0.3705 根据安装的 .NET FRAMEWORK 的版本决定。
键入 aspnet_regiis -i。
最后,在 IIS 中会出现一个 CrystalReportWebFormViewer Web 共享目录。
针对我的情况,联想到我没有使用IIS默认的网站,而我的发布目录中没有此文件夹,于是先到C:\inetpub\wwwroot中找,结果找到C:\inetpub\wwwroot\aspnet_client\system_web\2_0_50727\CrystalReportWebFormViewer4
正是我想要的,直接 拷到我的VS2008开发项目中,
![](http://images.cnblogs.com/cnblogs_com/wsdj-ittech/2010Y/2010Y5M/2.png)
重新编译、发布,于是在我的发布目录中出现了缺失的目录资源。重新运行网站,出现了相关图片
开发的网站没有使用系统默认的wwwroot目录,而是另建了一个目录 D:\published 做为网站的目录。
用Crystal Report2008在VS2008中开发报表,显示 正常,但当发布到网站上时水晶报表页没有图片,显示如下图,但是工作正常。
![](http://images.cnblogs.com/cnblogs_com/wsdj-ittech/2010Y/2010Y5M/1.png)
于是找原因,分析网页源码,找到代码如下:
<table cellspacing=0 cellpadding=0><tr nowrap>
<td nowrap width=8> </td><td nowrap width=22px><input type="image" name="CrystalReportViewer1$ctl02$ctl00" disabled="disabled" title="Export" src="/aspnet_client/system_web/2_0_50727/CrystalReportWebFormViewer4/images/toolbar/export.gif" onmouseover="this.src='/aspnet_client/system_web/2_0_50727/CrystalReportWebFormViewer4/images/toolbar/export_over.gif'" onmouseout="this.src='/aspnet_client/system_web/2_0_50727/CrystalReportWebFormViewer4/images/toolbar/export.gif'" style="height:22px;width:22px;border-width:0px;" /></td>
<td nowrap width=8> </td><td nowrap width=22px><input type="image" name="CrystalReportViewer1$ctl02$ctl01" disabled="disabled" title="Print" src="/aspnet_client/system_web/2_0_50727/CrystalReportWebFormViewer4/images/toolbar/print.gif" onmouseover="this.src='/aspnet_client/system_web/2_0_50727/CrystalReportWebFormViewer4/images/toolbar/print_over.gif'" onmouseout="this.src='/aspnet_client/system_web/2_0_50727/CrystalReportWebFormViewer4/images/toolbar/print.gif'" style="height:22px;width:22px;border-width:0px;" /></td>
<td nowrap width=8> </td><td nowrap width=22px><input type="image" name="CrystalReportViewer1$ctl02$ctl03" disabled="disabled" title="Show/Hide Group Tree" src="/aspnet_client/system_web/2_0_50727/CrystalReportWebFormViewer4/images/toolbar/grouptree.gif" onmouseover="this.src='/aspnet_client/system_web/2_0_50727/CrystalReportWebFormViewer4/images/toolbar/grouptree_over.gif'" onmouseout="this.src='/aspnet_client/system_web/2_0_50727/CrystalReportWebFormViewer4/images/toolbar/grouptree.gif'" style="height:22px;width:22px;border-width:0px;" /></td>
根据源码,估计是因为网站没有找到图片资源所致,于是回到网站发布 目录,发现目录下的确并没有"/aspnet_client/system_web/2_0_50727/CrystalReportWebFormViewer4/images/toolbar/export.gif”等等资源
网上有一说:IIS下没有此类资源的原因是: 没有安装 Crystal Report Web Service,或者没有在IIS中注册。
针对此类情况,通常的解决办法 是:
![](http://images.cnblogs.com/OutliningIndicators/ExpandedBlockStart.gif)
安装 Crystal Report Web Service:通过VS.NET安装,自动注册。
注册:首先进入MSDOS方式(可通过“开始”-“运行...”,键入cmd,回车)。
将 C:\WINDOWS\Microsoft.NET\Framework\v1.0.3705 作为当前目录,其中 C:\WINDOWS 根据操作系统的安装位置决定,v1.0.3705 根据安装的 .NET FRAMEWORK 的版本决定。
键入 aspnet_regiis -i。
最后,在 IIS 中会出现一个 CrystalReportWebFormViewer Web 共享目录。
针对我的情况,联想到我没有使用IIS默认的网站,而我的发布目录中没有此文件夹,于是先到C:\inetpub\wwwroot中找,结果找到C:\inetpub\wwwroot\aspnet_client\system_web\2_0_50727\CrystalReportWebFormViewer4
正是我想要的,直接 拷到我的VS2008开发项目中,
![](http://images.cnblogs.com/cnblogs_com/wsdj-ittech/2010Y/2010Y5M/2.png)
重新编译、发布,于是在我的发布目录中出现了缺失的目录资源。重新运行网站,出现了相关图片
![](http://images.cnblogs.com/cnblogs_com/wsdj-ittech/2010Y/2010Y5M/3.png)
相关文章推荐
- 解决ASP.NE页面水晶报表不显示工具栏图标的问题
- 解决ASP.NE页面水晶报表不显示工具栏图标的问题
- 解决ASP.NE页面水晶报表不显示工具栏图标的问题
- 解决水晶报表不显示工具栏图标的问题
- 【分享】VS200X水晶报表边框效果在WEB页面不连续显示问题解决方法
- 解决,水晶报表,在PC机显示正常,但放到服务器后不能正常显示工具栏,只显示X的图标
- 发布到SPS站点下的ASP.NET页面上的中文不能正常显示__问题解决方法
- 解决jasperreports报表在HTML页面显示的PX图片的问题
- wkhtmltopdf 将highcharts的页面转为pdf 图表加载不上问题 或者图标显示不全问题解决
- 水晶报表客户端不能导出、打印,图标显示不正常之解决办法
- 水晶报表中文本型长字段的等宽显示的问题解决.ASP.NET2005
- QAction setIcon,菜单和工具栏不显示图标的问题解决
- 水晶报表图片不显示两种问题分析及解决方法
- ASP.NET 水晶报表在iis中无法显示的解决办法
- ueditor的工具栏显示乱码解决方法 小问题.. 是你的页面编码与语言包js编码不符所导致的
- Asp.net 2.0 水晶报表部署问题解决
- 在做水晶报表时,打印,导航等工具图标全部显示为叉叉的解决方法
- Asp.net 2.0 水晶报表部署问题解决
- Asp.net 2.0 水晶报表部署问题解决
- 水晶报表图片不显示两种问题分析及解决方法