?
Solved

Dropdownlist box readonly

Posted on 2004-08-25
5
Medium Priority
?
2,525 Views
Last Modified: 2008-01-09
How Can I make dropdownlist box readonly on the webpage on certain conditions

Thanks
0
Comment
Question by:jra2002
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
5 Comments
 
LVL 10

Expert Comment

by:jnhorst
ID: 11897687
C#:
if (someCondition)  dropDownList.Attributes.Add("readonly", "true");

VB.NET

If someCondition Then dropDownList.Attributes.Add("readonly", "true")

John
0
 

Author Comment

by:jra2002
ID: 11902522
It is not working this syntax what you suggested,

I had fixed it with

dropdownlist.Enabled = False
0
 
LVL 10

Expert Comment

by:jnhorst
ID: 11903212
OK... Enabled/Disabled is a different property than "readonly", but that's fine.  Good that you got it working!

John
0
 

Accepted Solution

by:
ee_ai_construct earned 0 total points
ID: 11947440
Closed, 20 points refunded.
ee_ai_construct (replacement part #xm34)
Community Support Moderator
0

Featured Post

VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Just a quick little trick I learned recently.  Now that I'm using jQuery with abandon in my asp.net applications, I have grown tired of the following syntax:      (CODE) I suppose it just offends my sense of decency to put inline VBScript on a…
Problem Hi all,    While many today have fast Internet connection, there are many still who do not, or are connecting through devices with a slower connect, so light web pages and fast load times are still popular.    If your ASP.NET page …
In this video we outline the Physical Segments view of NetCrunch network monitor. By following this brief how-to video, you will be able to learn how NetCrunch visualizes your network, how granular is the information collected, as well as where to f…
NetCrunch network monitor is a highly extensive platform for network monitoring and alert generation. In this video you'll see a live demo of NetCrunch with most notable features explained in a walk-through manner. You'll also get to know the philos…
Suggested Courses

770 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question