本文介绍了如何在文本框中显示逗号但不保存到数据库?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在VS2010工作。使用C#Web表单。我在网络表单上有一个文本框,我试图在用户输入数字时显示逗号。在AJax中有一个maskedtextbox控件。有没有办法在Web表单上的文本框中显示逗号?如果是这样,有人可以告诉我如何?谢谢。

I am working out of VS2010. Using C# web forms. I have a textbox on a web form and I am trying to get it to display commas when a user enters numbers. In AJax there was a maskedtextbox control for this. Is there a way to display commas in a textbox that is on a web form? If so, can someone show me how? Thanks.

推荐答案

string value=txtValue.Text.Replace(",","");



这篇关于如何在文本框中显示逗号但不保存到数据库?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

08-20 07:32
查看更多