Quantcast
Channel: VBForums - Visual Basic 6 and Earlier
Viewing all articles
Browse latest Browse all 21088

[RESOLVED] syntax error

$
0
0
what is missing here?:confused:
Code:

CN.Execute "INSERT INTO Appointments (AppID, AppDate, AppTime, AppCust, AppHrDr, AppService, AppRemarks) VALUES (" & _
            NewID & ", #" & _
            MyDate(PckDate.Value) & "#, '" & _
            CmbEnd.text & " - " & CmbStart.text & "', " & _
            CmbCust.ItemData(CmbCust.ListIndex) & ", " & _
            CmbHrDr.ItemData(CmbHrDr.ListIndex) & ", '" & _
            RplS(TxtService.text) & "', " & _
            RplS(Text1.text) & "')"

and here
Code:

      With FrmApps.LsVwHrDr.SelectedItem
            CN.Execute "UPDATE Appointments SET " & _
                "AppDate= #" & MyDate(PckDate.Value) & "#, " & _
                "AppTime= '" & CmbEnd.text & " - " & CmbStart.text & "', " & _
                "AppCust= " & CmbCust.ItemData(CmbCust.ListIndex) & ", " & _
                "AppService= '" & RplS(TxtService.text) & ", " & _
                "AppRemarks='" & RplS(Text1.text) & "' " & _
                "WHERE AppID= " & .Tag
            .text = Format(PckDate.Value, "dd/mm/yyyy")
            .SubItems(2) = CmbEnd.text & " - " & CmbStart.text
            .SubItems(3) = TxtService.text
            .SubItems (4)= Text1.text


Viewing all articles
Browse latest Browse all 21088

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>