1-I want insert & update and read from oledbconnection from sqlserver 2000 data base example :
Private Sub BtSave_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles BtSave.Click
Dim SqlSt As String
If NewRec Then
SqlSt = "INSERT INTO category (category_code,category_name,category_paper_kind_and_weight,category_color,category_cut_measurement,category_original,category_copy,category_id1,category_id2,category_picture,category_notes) VALUES (" _
& txtcode.Text & ",'" & txtcategory_name.Text & "','" & txtcategory_paper_kind_and_weight.Text & "','" & txtcategory_color.Text & "','" & txtcategory_cut_measurement.Text & "','" & _
txtcategory_original.Text & "','" & txtcategory_copy.Text & "','" & txtcategory_at.Text & "','" & txtcategory_to.Text & "','" & Piccategory.ImageLocation & "','" & txtcategory_notes.Text & "')"
Else
SqlSt = "Update category set category_code=" & txtcode.Text & ",category_name='" & txtcategory_name.Text & "' ,category_paper_kind_and_weight='" & txtcategory_paper_kind_and_weight.Text & "' ,category_color='" & txtcategory_color.Text & _
"' ,category_cut_measurement='" & txtcategory_cut_measurement.Text & "' ,category_original='" & txtcategory_original.Text & "' ,category_copy='" & txtcategory_copy.Text & "' ,category_id1='" & txtcategory_at.Text & "' ,category_id2='" & txtcategory_to.Text & "' ,category_picture='" & Piccategory.ImageLocation & "',category_notes='" & txtcategory_notes.Text & "'where category_id=" & txtcode.Tag
End If
OleDbm.OleDbx.ExStatment(SqlSt, SubCon)
LBCount.Text = OleDbm.OleDbx.ExStatment("select count(category_id) from category", SubCon)
BtnMode(True, False)
Me.CategoryTableAdapter.Fill(Me.Dstprinthouse.category)
End Sub
In this Example i make on picture bold and italc how to write picturebox.
what
2- how to view the picture in datagrideview but i am file data in datagrideview withe dataset