SitePoint Sponsor

User Tag List

Results 1 to 4 of 4
  1. #1
    SitePoint Guru
    Join Date
    Dec 2008
    Posts
    692
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    make contorls readonly

    i want to lock/make contorls readonly

    at presnt i have this code

    TXTADD3.Disabled = True

    drpdwncity.Enabled = False

    the problem is TXTADD3.readonly(property) is not avaliable. this is a html textbox

    secondaly if i use .Disabled = True then the text appears loght/blur . so is there any property by which the controls will be locked and the user cannot make any changes

  2. #2
    SitePoint Mentor NightStalker-DNS's Avatar
    Join Date
    Jul 2004
    Location
    Cape Town, South Africa
    Posts
    2,873
    Mentioned
    45 Post(s)
    Tagged
    0 Thread(s)
    Enabled = false. Disabled is not a property

  3. #3
    SitePoint Guru
    Join Date
    Dec 2008
    Posts
    692
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    for that control i dont have enabled property

  4. #4
    SitePoint Mentor NightStalker-DNS's Avatar
    Join Date
    Jul 2004
    Location
    Cape Town, South Africa
    Posts
    2,873
    Mentioned
    45 Post(s)
    Tagged
    0 Thread(s)
    Then just do it manually:

    TXTADD3.Attributes.Add("readonly","readonly");

    Any reason its an HtmlInputText and not TextBox?


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •