Once again I am left scratching my head. I have a checkbox that I want to store in my DB as either '1' if checked or "Null" if not checked. I read through at least 50 posts that are similar but the answer is still eluding me. I know the stored procedure
is right and the web side stuff is mainly right, except for the checked value of the checkbox. If I don't check it, it does write make the DB entry 'Null', if i check it, the DB entry is 'on'. Here is the code and HTML of the page. I know my problem is
with the var line, I just don't know how to make the action of the button pick up the values I want for the checkbox.
<%@Page Language="C#" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<script runat="server">
private void InsertCard (object source, EventArgs e) {
SqlDa ...
Go to the complete details ...