Click here to Skip to main content
15,883,820 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hello there ,i have situation in which if i set the value of checkbox to false once in my database then it cannot be set to true again.

pls help me with the code.
Posted
Comments
raeeschaudhary 3-Apr-13 3:55am    
give some detail what you want to do. question doesn't look to be answerable

1 solution

Hi,

As per my understanding,
1. if your database value was set as false , don't enable check box list (i.e. checkbox.Enabled = false)
2. instead of check box list you can use radio button list

please elaborate your question if you need accurate results

Regards,
--SJ
 
Share this answer
 
Comments
Syed.net 3-Apr-13 5:11am    
@Sj
what my question mean is that whenever i m selecting the checkbox it sends 'True' to database , but after sometime if i m unchecking the checkbox then it should stay as unchecked ('False' in Database) and no modification could be done next
codeninja-C# 4-Apr-13 3:41am    
@syed,
following logic might work
if(database.checkbox.value == false)
checkbox.enabled = false;
else
checkbox.enabled = true;

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900