Wrox Programmer Forums
Go Back   Wrox Programmer Forums > Visual Basic > VB 6 Visual Basic 6 > VB Components
|
VB Components Issues specific to components in VB.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the VB Components section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old December 6th, 2005, 07:21 AM
Registered User
 
Join Date: Dec 2005
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default How to i save checkbox value to database ADO

How to i save checkbox value to database ADO??



 
Old December 13th, 2005, 06:19 PM
Friend of Wrox
 
Join Date: Nov 2004
Posts: 1,621
Thanks: 1
Thanked 3 Times in 3 Posts
Default

Code:
    If ctrl.checked = True Then
        cmd.CommandText = "UPDATE table     " & _
                          "SET field = TRUE " & _
                          "WHERE ID =  whatever "
    Else
        cmd.CommandText = "UPDATE table     " & _
                          "SET field = TRUE " & _
                          "WHERE ID =  whatever "
    End If
    cmd.Execute





Similar Threads
Thread Thread Starter Forum Replies Last Post
Save checkbox settings to cookie clockwork Beginning PHP 1 November 20th, 2007 05:45 AM
i cannot save to my database knightneo Beginning PHP 3 January 29th, 2007 08:06 AM
Save Checkbox with boolean 0/1 value rdove84 ASP.NET 1.0 and 1.1 Basics 5 October 24th, 2006 09:12 AM
save database kim Visual Basic 2005 Basics 0 March 20th, 2006 04:34 PM
checkbox from database ? please help me. majidnakit JSP Basics 0 September 14th, 2005 03:53 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.