HTML   发布时间:2022-04-14  发布网站:大佬教程  code.js-code.com
大佬教程收集整理的这篇文章主要介绍了Crystal Report显示HTML文本,但子弹不显示.为什么?大佬教程大佬觉得挺不错的,现在分享给大家,也给大家做个参考。
我从SQL-Server nvarchar(3000)字段中获取数据,该字段格式为html,在Crystal Reports 11中显示它.数据被保存为项目符号,如果我将数据拉出并放入带有html扩展名的文本文件,它显示了项目符号.但是从Crystal,它没有.我得到新线,但没有子弹.

保存的字段如下所示:

<HTML><BODY><DIV STYLE="text-align:Left;font-family:Tahoma;font-style:normal;font-weight:normal;font-size:11;color:#000000;"><DIV><DIV><P><SPAN>This is a bulleted list</SPAN></P><UL><LI><P><SPAN>One</SPAN></P></LI><LI><P><SPAN>Two</SPAN></P></LI><LI><P><SPAN>Three</SPAN></P></LI></UL><P><SPAN /></P></DIV></DIV></DIV></BODY></HTML>

在Crystal中,它看起来像这样

This is a bulleted list 
One 
Two 
Three

换句话说,没有子弹.为什么不?

解决方法

无论出于何种原因,Crystal Reports只支持HTML标记的子集.根据 this forum thread,子弹不是其中之一.

为了后人的缘故,这里是支持的HTML标签的声称列表:

html
body
div (causes a paragraph break)
tr (causes only a paragraph break; does not preserve column structure of a tablE)
span
font
p (causes a paragraph break)
br (causes a paragraph break)
h1 (causes a paragraph break,makes the font bold & twice default sizE)
h2 (causes a paragraph break,makes the font bold & 1.5 times default sizE)
h3 (causes a paragraph break,makes the font bold & 9/8 default sizE)
h4 (causes a paragraph break,makes the font bold)
h5 (causes a paragraph break,makes the font bold & 5/6 default sizE)
h6 (causes a paragraph break,makes the font bold & 5/8 default sizE)
center
big (increases font size by 2 points)
small (decreases font size by 2 points if it's 8 points or larger)
b
i
s
Strike
u

大佬总结

以上是大佬教程为你收集整理的Crystal Report显示HTML文本,但子弹不显示.为什么?全部内容,希望文章能够帮你解决Crystal Report显示HTML文本,但子弹不显示.为什么?所遇到的程序开发问题。

如果觉得大佬教程网站内容还不错,欢迎将大佬教程推荐给程序员好友。

本图文内容来源于网友网络收集整理提供,作为学习参考使用,版权属于原作者。
如您有任何意见或建议可联系处理。小编QQ:384754419,请注明来意。