Updating in Visual Basic

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • gregory21
    New Member
    • Oct 2011
    • 1

    Updating in Visual Basic

    I'm insert my information into a SQL table, but I wont to make changes to older record if needed. So I begin with an UpDate Statement, but I'm having problem with the code to go through into the SQL Table for in update.


    Here's the update code:

    "Update [BLL_Program] Set [Number of Problem] = " & TextBox1.Text & " [Problem Type] = '" & ComboBox2.Selec tedText & " where [Day] = '" & NumericUpDown2. Value & "' and [Month] = ' " & NumericUpDown1. Value & "'and [Year] = '" & ComboBox1.Selec tedText & "'")


    Thanks.
    Last edited by Niheel; Nov 1 '11, 06:22 PM. Reason: no need for all caps
  • Rabbit
    Recognized Expert MVP
    • Jan 2007
    • 12517

    #2
    Output the SQL string so you can verify the syntax.

    Comment

    Working...