且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

GridView控件是修剪前导空格。我可以停止?

更新时间:2021-11-23 06:41:54

怎么样,当你绑定您的数据,以取代所有 字符&放大器; NBSP; 。您可以用OnRowDataBound事件或通过DataFormatString做到这一点(这里有一个相关的例子

How about, when you bind your data, replace all '' characters with ' '. You can do this with a OnRowDataBound event or through DataFormatString (here's a relevant example).