Watemark文本正在影响文本框的值 [英] Watemark text is affecting textbox value

查看:111
本文介绍了Watemark文本正在影响文本框的值的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述



我在文本框中使用水印.如果我得到那个文本框,它将得到水印文本.但是我只想获取空值.

Hi,

I m using watermark in my textbox. If i get that textbox it get watermark text. But I want to get empty value only.

How to do it?

推荐答案

嗨..
看到这个,可能对你有用.
Hi..
See this,its may useful to u.
<asp:TextBox ID="TextBox6" runat="server"></asp:TextBox>
                                       <asp:TextBoxWatermarkExtender ID="TextBoxWatermarkExtender4" runat="server"

                                           TargetControlID="TextBox6" WatermarkCssClass="Water Mark"

                                           WatermarkText="Amount In Rs....">
                                       </asp:TextBoxWatermarkExtender>
                                       <asp:RequiredFieldValidator ID="reqfieldvaldatorDepositForReg" runat="server"

                                           ControlToValidate="TextBox6" Display="Dynamic"

                                           ErrorMessage="Deposit should not be empty" ForeColor="#CC0000"

                                           ValidationGroup="pnl"></asp:RequiredFieldValidator>



像这样使用,谢谢.



Use like this,Thank u.


查看此打击链接.
http://www.dotnetcurry.com/ShowArticle.aspx?ID=241 [ ^ ]
谢谢你.
See this blow links.
http://www.dotnetcurry.com/ShowArticle.aspx?ID=241[^]
Thank u.


检查一下...
使用javascript的水印文本框 [
check this...
watermark textbox using javascript[^]


这篇关于Watemark文本正在影响文本框的值的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆