2010-10-20 10 views
6

Sto recuperando i dati da un campo nvarchar (3000) di SQL Server, che è formattato come html, visualizzandolo in Crystal Reports 11. I dati vengono salvati come punti elenco e se estraggo i dati e li rilasciamo in un file di testo con estensione html, mostra i punti elenco. Ma da Crystal, non è così. Prendo la nuova linea, ma non i proiettili.Crystal Report che mostra testo HTML, ma i punti elenco non vengono visualizzati. Perché?

Il campo che viene salvato assomiglia a questo:

<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> 

E in cristallo, sembra che questo:

This is a bulleted list 
One 
Two 
Three 

In altre parole, non proiettili. Perchè no?

+0

Che cosa succede se si taglia '

  • Uno

  • ' verso '
  • One
  • '? – drudge

    +0

    Non ho un grande controllo sul modo in cui i dati vengono salvati (app in C# .net, una sorta di barra degli strumenti e un editor di testo). Tuttavia, ho modificato i dati nel database e questo non ha fatto la differenza. Si è ancora mostrato correttamente nell'app, non ha ancora proiettili in Crystal. – thursdaysgeek

    risposta

    5

    Per qualsiasi motivo, Crystal Reports ha sempre supportato solo un sottoinsieme di tag HTML. Secondo this forum thread, i proiettili non sono uno di questi.

    Per l'amor di posteri, ecco la lista presunto dei tag HTML supportati:

    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 
    
    Problemi correlati