SqlDataReader Problem

  • Thread starter Thread starter joelranck
  • Start date Start date
J

joelranck

I'm trying to grab some text from my database that is html formatted.
The problem is all the html formatting is lost when I try and get it
from my SqlDataReader.

sqlCmd = new SqlCommand(sqlQuery, sqlConn);
sqlRead = sqlCmd.ExecuteReader();
while (sqlRead.Read()) {
FCKeditor.Value = sqlRead.GetString(0);
}

This obviously isn't the right way to do it.. any ideas?
 
Do a Select and see if the data in the db is indeed stored as HTML first.
dr.GetSqlXml shoukd have worked if the data was XML/HTML.


--
With Regards
Shailen Sukul
..Net Architect
(MCPD: Ent Apps, MCSD.Net MCSD MCAD)
Ashlen Consulting Services
http://www.ashlen.net.au
 
Back
Top