473,395 Members | 1,521 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,395 software developers and data experts.

Problems Setting the TextBox.Text Property

Hello there,
I'm having some problems setting the TextBox.Text Property in my code and
having it returned to the client in the source when the
TextBox.TextMode="Password".

I know this is generally not a good idea to fill it with the actual password
but I would like to put '*'s in it as place holders just so it looks like
the password is actually typed out in there.

Thanks,

David Kyle
www.chloemag.com
Nov 18 '05 #1
4 2023
Exactly what problems are you having?

Tom Dacon
Dacon Software Consulting

"David Kyle" <dk***@chloemag.com> wrote in message
news:e$****************@TK2MSFTNGP14.phx.gbl...
Hello there,
I'm having some problems setting the TextBox.Text Property in my code and
having it returned to the client in the source when the
TextBox.TextMode="Password".

I know this is generally not a good idea to fill it with the actual
password but I would like to put '*'s in it as place holders just so it
looks like the password is actually typed out in there.

Thanks,

David Kyle
www.chloemag.com

Nov 18 '05 #2
lol, can't believe I didnt' actually say what the problem was. Absent
minded after 3 days 16 hours a day programing i guess.

anyways, basically the problem is when I assign a value to the TextBox.Text
property it doesn't send that information back to the client in the source.

eg.
OnPageLoad() {
txtPassword.Text = "123456";
}

<asp:textbox id="txtPassword" textmode="Password" runat="server" />

returned source:
<input name="txtPassword" type="password" id="txtPassword" />

There's no value="123456" in the input tag that is sent to the client.

I think this explains it.

thanks for any help.

Dave
"Tom Dacon" <td****@community.nospam> wrote in message
news:Oj**************@TK2MSFTNGP12.phx.gbl...
Exactly what problems are you having?

Tom Dacon
Dacon Software Consulting

"David Kyle" <dk***@chloemag.com> wrote in message
news:e$****************@TK2MSFTNGP14.phx.gbl...
Hello there,
I'm having some problems setting the TextBox.Text Property in my code and
having it returned to the client in the source when the
TextBox.TextMode="Password".

I know this is generally not a good idea to fill it with the actual
password but I would like to put '*'s in it as place holders just so it
looks like the password is actually typed out in there.

Thanks,

David Kyle
www.chloemag.com


Nov 18 '05 #3
PasswordField.Attributes.Add("value", "secret")

Here's a link..

http://www.devx.com/vb2themax/Tip/18887

"David Kyle" <dk***@chloemag.com> wrote in message
news:e$****************@TK2MSFTNGP14.phx.gbl...
Hello there,
I'm having some problems setting the TextBox.Text Property in my code and
having it returned to the client in the source when the
TextBox.TextMode="Password".

I know this is generally not a good idea to fill it with the actual password but I would like to put '*'s in it as place holders just so it looks like
the password is actually typed out in there.

Thanks,

David Kyle
www.chloemag.com

Nov 18 '05 #4
Thanks Michael! it works great now!
"Michael" <xxx.xxx.xxx> wrote in message
news:%2****************@TK2MSFTNGP12.phx.gbl...
PasswordField.Attributes.Add("value", "secret")

Here's a link..

http://www.devx.com/vb2themax/Tip/18887

"David Kyle" <dk***@chloemag.com> wrote in message
news:e$****************@TK2MSFTNGP14.phx.gbl...
Hello there,
I'm having some problems setting the TextBox.Text Property in my code and
having it returned to the client in the source when the
TextBox.TextMode="Password".

I know this is generally not a good idea to fill it with the actual

password
but I would like to put '*'s in it as place holders just so it looks like
the password is actually typed out in there.

Thanks,

David Kyle
www.chloemag.com


Nov 18 '05 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
by: Gill Smith | last post by:
After setting the web control text box enable property to FALSE makes the control to loose the data between round trip. I am making sure that the property - EnableViewState = TRUE. Same code...
3
by: Justin Morris via DotNetMonster.com | last post by:
<asp:TextBox ID="TextBox1" runat="server" value='<%=Server.HtmlEncode (Request.Cookies("Username")("Username"))%>'/> <input name="Password" type="text" id="Password" value='<%...
3
by: The One | last post by:
Have created a form to pop up with 2 option I then wish to write the text that is in the option button chose back to the original form using the code below but it gives me an exception error so...
16
by: pamelafluente | last post by:
I am still working with no success on that client/server problem. I need your help. I will submit simplified versions of my problem so we can see clearly what is going on. My model: A client...
4
by: tshad | last post by:
I am trying to hide and show certain parts of my code (which I have no problem doing with DW). In VS 2003, it won't let you use <div runat="server"to section of parts of my code in a table. This...
1
by: FordPrefect | last post by:
I am using a 3rd party dll (not COM). One of the dll functions requires a callback function. I have used either DllImport or Declare to properly (I think) declare the function. The function...
18
by: Academia | last post by:
I let the use modify the text of a combobox and then I replace the selected item with the new text (in Keyup event). But if he sets the Text property to an empty string ("") that sets the...
1
by: =?Utf-8?B?Q2hyaXN0aWFuIFdlaW5lcnQ=?= | last post by:
Hello, I currently fight with a problem during the derivative of WinForm controls. In Visual Studio I created a new User Control. This control is derived from the DataGridView of the...
3
by: =?Utf-8?B?R3JlZw==?= | last post by:
I am used to using third party controls when it comes to setting up appearences. But, now I am using Visual Basic.Net controls that come standard with the product. I've come across a frustration...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.