0

I created a Save button and I also have made the code for the Save button
But why the error message like this:

Run-time error '-2147217913(80040e07)
convension failed when converting the varchar value '28/08/2013 10:11:01 to data type bit

mohon bantuannya,
thanks,
V

5
Contributors
14
Replies
39
Views
4 Years
Discussion Span
Last Post by vividiah
Featured Replies
  • > how should bring a DateTimePicker? You can find it in Tool Box. Look harder you will find it. Read More

0

Stuugie:
I also do not understand why there is an error like this, but it is used typenya all data types DATE / TIME,
do i need to explain the code SAVE?
thanks

0

this is my code:

SQLTambah = "INSERT INTO iMUSIC " & _
        "(ID_MUSIC, TITLE, SINGER, FID_M_CATEGORY, FILE_NAME, SOURCE, PATH, ACTIVE, VOL , ANALOG, DATE_ADDED)" & _
        " VALUES (" & _
        "'" & Text1.Text & "', " & _
        "'" & Text7.Text & "', " & _
        "'" & Text3.Text & "', " & _
         "'" & Text9.Text & "', " & _
        "'" & Text2.Text & "', " & _
         "'" & Text5.Text & "', " & _
        "'" & Text8.Text & "', " & _
         "'" & Label11.Caption & "', " & _
          "'" & Text10.Text & "', " & _
           "'" & Combo2.Text & "', " & _
            "'" & Label1.Caption & "' " & _ 'this is This label is used to display the date
        ")"
                 conn.Execute SQLTambah
0

If datatype of DATE_ADDED is datetime in table iMUSIC, then you need to use a DateTimePicker instead of a Label.

While passing parameter you need to use conversion like this:

DateValue(DateTimePicker1.Value.Date)

Do the above and check.

0

Rahul47 :
how should bring a DateTimePicker?
I've been looking for the whole time of its existence but did not find,
please help,

1

how should bring a DateTimePicker?

You can find it in Tool Box. Look harder you will find it.

0

can you tell what you are in search of ?
are you in search of how to add date and time?
I can't understand what you mean./..
so please can you elaborate it.?

0

DM Galaxy :
yes I am looking for the components of the date and time,
according to the suggestions of Rahul47, I have to use the DateTimePicker,
and I was looking for the location of the DateTimePicker,
if you can help me to find it?

0

Rahul47:

Okay I'll look harder about it,
okay thanks for all the advice and help,
regards,

0

I don'see how you are not able to find DateTimePicker as it is present in ToolBox itself. I hope you are not missing it by chance.

0

as to see the code of date and time then watch the below codes:
Label1 as time and
label2 as date

Label1.Text = TimeOfDay
Label2.Text = DateString

I think this code will tell you the time as well as date too.
If i just misunderstood what you tell me then please correct me by elaborating the data...

0

oh I've found the components of the
thank you for all your help,

Vivi

This question has already been answered. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.