User Name Password Register
DaniWeb IT Discussion Community
All
What is DaniWeb IT Discussion Community?
You're currently browsing the ASP.NET section within the Web Development category of DaniWeb, a massive community of 402,544 software developers, web developers, Internet marketers, and tech gurus who are all enthusiastic about making contacts, networking, and learning from each other. In fact, there are 2,308 IT professionals currently interacting right now! Registration is free, only takes a minute and lets you enjoy all of the interactive features of the site.
Please support our ASP.NET advertiser: Lunarpages ASP Web Hosting
Views: 654 | Replies: 2 | Solved
Reply
Join Date: Aug 2007
Location: Somewhere between heaven and hell
Posts: 94
Reputation: Kusno is an unknown quantity at this point 
Rep Power: 2
Solved Threads: 6
Kusno's Avatar
Kusno Kusno is offline Offline
Junior Poster in Training

RadioButtonList matter

  #1  
Aug 27th, 2007
Dear all .Netters,

I want my RadioButtonList can not be selected by users, so i set the Enable to be false. The problem is the font colour become gray.

so does any one of you can help me how to keep the font colour still black and can not be selected ?


Thanks and Regards,


Kusno
AddThis Social Bookmark Button
Reply With Quote  
Join Date: May 2006
Location: Bellevue, WA
Posts: 1,548
Reputation: Infarction has a spectacular aura about Infarction has a spectacular aura about Infarction has a spectacular aura about 
Rep Power: 8
Solved Threads: 51
Sponsor
Infarction's Avatar
Infarction Infarction is offline Offline
Battle Programmer

Re: RadioButtonList matter

  #2  
Aug 27th, 2007
Try setting the font-color to black when you set enabled to false.
Reply With Quote  
Join Date: Aug 2007
Location: Somewhere between heaven and hell
Posts: 94
Reputation: Kusno is an unknown quantity at this point 
Rep Power: 2
Solved Threads: 6
Kusno's Avatar
Kusno Kusno is offline Offline
Junior Poster in Training

Re: RadioButtonList matter

  #3  
Aug 28th, 2007
Finnaly, i find the answer. i use checkboxlist control, because there is a bug in radiolbuttonlist control when RepeatColumn is set to 2

if form_load :
If Not IsPostBack Then
ViewState("Chk") = 2
CheckBoxList1.SelectedIndex = 2
End If

and .....

Protected Sub CheckBoxList1_SelectedIndexChanged(ByVal sender As Object, ByVal e As System.EventArgs) Handles CheckBoxList1.SelectedIndexChanged
CheckBoxList1.SelectedIndex = ViewState("Chk")
End Sub

It will push the selectedindex value to the viewstate value.
Last edited by Kusno : Aug 28th, 2007 at 2:56 am.
Reply With Quote  
Reply

Only community members can participate in forum threads. You must register or log in to contribute.

DaniWeb ASP.NET Marketplace
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)

 

Thread Tools Display Modes

Similar Threads
Other Threads in the ASP.NET Forum

All times are GMT -4. The time now is 8:34 pm.
Forum system based on vBulletin Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
©2003 - 2008 DaniWeb® LLC