471,347 Members | 1,683 Online
Bytes | Software Development & Data Engineering Community
Post +

Home Posts Topics Members FAQ

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

ASP.Net Readonly textbox

Hi!
I'm working in an application in VS2005. I have a Website that has a page
where the user has to fill in some dates. In 2003 I used to have a function
in javascript that would popup a calendar, the user would select the date
there and then that date would be entered in a read-only textbox, so I was
sure that the format was correct. Now this works ok in 2005, but when I try
to read the text from that textbox in codebehind, I always get what was on
the textbox when the page was rendered. I tried setting the readonly
attribute to false, and it works then, so it's most likely a bug. Does
anybody know a workaround??
Thanks in advance,

Matias
Dec 22 '05 #1
1 1515
Try setting the TextBox.Enabled property to False and then set the Text
property. The ReadOnly property prevents changing the original content.
--
Christopher A. Reed
"The oxen are slow, but the earth is patient."

"Matias" <ma****@matias.com> wrote in message
news:ub**************@TK2MSFTNGP10.phx.gbl...
Hi!
I'm working in an application in VS2005. I have a Website that has a page
where the user has to fill in some dates. In 2003 I used to have a
function in javascript that would popup a calendar, the user would select
the date there and then that date would be entered in a read-only textbox,
so I was sure that the format was correct. Now this works ok in 2005, but
when I try to read the text from that textbox in codebehind, I always get
what was on the textbox when the page was rendered. I tried setting the
readonly attribute to false, and it works then, so it's most likely a bug.
Does anybody know a workaround??
Thanks in advance,

Matias

Dec 22 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.

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.