كود :
Dim command As New SqlCommand("INSERT INTO table_name (image_column) VALUES (@image)", connection)
command.Parameters.AddWithValue("@image", DBNull.Value)
command.ExecuteNonQuery()كود :
If PictureBox1.Image Is Nothing Then
Dim command As New SqlCommand("INSERT INTO table_name (image_column) VALUES (@image)", connection)
command.Parameters.AddWithValue("@image", DBNull.Value)
command.ExecuteNonQuery()
Else
' code to insert the image
End If
