Friday, February 10, 2012

Bit to binary problem

I have a field in my database defined as a bit. I need to bind this field to a checkbox I have stored in a datgrid on my webform. I'm having problmes finding the right call in the html

<asp:CheckBox id="chkComplexity" runat="server" Width="125px" Text="Complexity"
WHAT TO PUT HERE !?!?!

</asp:CheckBox

Any help would be greatly appreciatedchkComplexity.Checked = (bool)Reader["CheckBoxField"];|||How wud u do the opposite?? I'm trying to get a bool value into a bit field in one of the fields in my table. Passing in a bool errors out.|||

Try this link it shows you how to get what is in SQL Server before you pass it any value because VB6 boolean evaluates to int. Hope this helps.

http://www.codecomments.com/archive317-2005-2-391341.html

No comments:

Post a Comment