但不显示项目符号

但不显示项目符号

本文介绍了Crystal Report 显示 HTML 文本,但不显示项目符号.为什么?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我从 SQL-Server nvarchar(3000) 字段中获取数据,该字段格式为 html,在 Crystal Reports 11 中显示.数据被保存为项目符号,如果我提取数据并删除它在一个带有 html 扩展名的文本文件中,它显示了项目符号.但从水晶,它没有.我得到了新的线路,但没有项目符号.

I'm getting data out of a SQL-Server nvarchar(3000) field, which is formatted as html, displaying it in Crystal Reports 11. The data is being saved as bullets, and if I pull out the data and drop it in a text file with an html extension, it shows the bullets. But from Crystal, it does not. I get the new line, but no bullets.

保存的字段如下所示:

<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 中,它看起来像这样:

And in Crystal, it looks like this:

This is a bulleted list
One
Two
Three

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

In other words, no bullets. Why not?

推荐答案

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

For whatever reason, Crystal Reports has only ever supported a subset of HTML tags. According to this forum thread, bullets are not one of them.

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

For posterity's sake, here is the purported list of supported HTML tags:

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 文本,但不显示项目符号.为什么?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

08-05 07:59