格式化从数据库的文本字段访问的文本数据 [英] formatting textual data accessed from database' text field
本文介绍了格式化从数据库的文本字段访问的文本数据的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我正在使用asp.net 3.5(c#)+ sql server 2008
我在数据库中有一个数据类型为(TEXT)的字段,我有多行文本数据,即summary
现在我想在asp.net页面上检索它,我确实做了,但是我将字段绑定到了标签的text属性,这是一种很差的方法,所以我该怎么做我提到的事情,还想对其进行格式化,即formatting
i am using asp.net 3.5(c#) + sql server 2008
i have a field in database with datatype (TEXT), i has multiple lines of textual data i.e summary
now i want to retrieve it on asp.net page, i did actually, but i binded the field to label''s text property , which is very poor approach so how how would i do what i mentioned and also want to format it i.e formatting
推荐答案
为什么不尝试使用Rich Text框控件?
用于ASP.NET 1.1的RichTextBox用户控件 [ ^ ]
http://www.textcontrol.com/en_US/sites/asp-dotnet-rich -text-box/ [ ^ ]
http://stackoverflow.com/questions/512068/best-free- richtextbox-for-asp-net-2-0 [ ^ ]
Why don''t you try to use a Rich Text box control?
RichTextBox user control for ASP.NET 1.1[^]
http://www.textcontrol.com/en_US/sites/asp-dotnet-rich-text-box/[^]
http://stackoverflow.com/questions/512068/best-free-richtextbox-for-asp-net-2-0[^]
感谢伙计们,但我使用了文字控件并将文本绑定到该控件.
thanks guys, but i used Literal control and binded my text to it.
这篇关于格式化从数据库的文本字段访问的文本数据的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文