Editable/Not Editable


Hello All,
I have some webform(.aspx page) in which i have some controls (for input) and i would like to make that screen editable/not editable based on some condition. how can i do that.
 the whole intent is user can read the information but can't change.
 shiva kumar
0
shivaatgenmills
4/30/2007 1:50:46 PM
📁 asp.net.getting-started
📃 91979 articles.
⭐ 3 followers.

💬 5 Replies
👁️‍🗨️ 1099 Views



If you want to make the controls editable/non-editable, you can set their ReadOnly property to true or false accordingly. What exactly do you imply by making the screen editable/non-editable?

Thanks,
Max
Let Me Google That For You!
0
bullpit
4/30/2007 2:37:59 PM
i mean to say i would like to show the current values but user should not modify them.
0
shivaatgenmills
4/30/2007 3:04:31 PM
ReadOnly property is the way to go...

Thanks,
Max
Let Me Google That For You!
0
bullpit
4/30/2007 3:09:15 PM
Thanks bullpit.
0
shivaatgenmills
4/30/2007 3:33:49 PM

You can do it with javascript:  
    document.getElementById('TextBox1').readOnly = true;
  

Hope this helps!  Don't forget to mark the most helpful post(s) as Answer for the sake of future readers.  Thanks!

Josh Stodola   ← Come check out my blog!
0
JoshStodola
4/30/2007 3:36:41 PM
Reply: