Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 2 of 2
  1. #1
    New Coder
    Join Date
    Jan 2003
    Posts
    99
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Exclamation how i can Insert into data base with check box

    If i want add into database with check box
    For example

    I have massage forum and i want the member send massage to multiple user
    These codes for send to one user. I want change this code to send to multiple user ((form check box))
    ===========================================

    Dim objConn , objRS , strQ , strConn, strOutput
    Set objConn = Server.CreateObject("ADODB.Connection")

    objConn.Open "Provider=Microsoft.Jet.OLEDB.4.0; Data Source=" & Server.MapPath("users.mdb") & ";"
    Set objRS = Server.CreateObject("ADODB.Recordset")


    strQ1 = "SELECT * FROM internalmail "




    objRS.Open strQ1 , objConn , 1, 2
    If Request.form("submit") = "send" Then

    objRS.AddNew
    objRS("sender") = Request.QueryString("username")
    objRS("reciever") = Request.form("to")
    objRS("subject") = Request.form("subject")
    objRS("message") = Request.form("message")
    objRS("date") = Date()
    objRS.Update

    End If

    'Response.Write Request.QueryString("username")

  • #2
    Senior Coder Morgoth's Avatar
    Join Date
    Jun 2002
    Location
    Ontario, Canada Remaining Brain Cells: 6
    Posts
    1,402
    Thanks
    2
    Thanked 1 Time in 1 Post
    So let me get this straight.

    When the user sumbits a form, and if the checkbox is checked you want it to add it into a database? And if it's not checked you want it to send the e-mail?


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •