Hi i have a checkbox and in code behind i insert the value from checkbox into the DB. This is what i did:
ClassRegInfo order1 = new ClassRegInfo
{
classID = classID.Text,
ObtainedPermission = Convert.ToByte(obtainedPermission.Checked)}
Obtained Permission in DB is of type bit. So when I do the above step, i get an error:
Cannot implicitly convert type byte to bool
So, can u let me know how to store the value as a bit in DB?
Dont convert it to byte. Bit equals Bool