please..
can you help me to load & insert image into SQL VB.net sample code will be great.
thx b4
and another thing, how can we make an on the fly events such as onclick of a button
please..
can you help me to load & insert image into SQL VB.net sample code will be great.
thx b4
and another thing, how can we make an on the fly events such as onclick of a button
CF to load&insert image datatype into SQL Server 2005?
SKS72
SokSa.Icy
Simply do this with existing row; rest of the code remains unchanged:
myRow("img") = MyData
ThE ViKinG
thanks Ilya for your reply..
but I decided to use a parameter from querystring to do the update
Mark Macumber
thanks Ilya, but i found another link
this is how I insert
Dim fs As New FileStream _(OpenFileDialog1.FileName, FileMode.OpenOrCreate, _
FileAccess.Read)
Dim MyData(fs.Length) As Bytefs.Read(MyData, 0, fs.Length)
fs.Close()
con.Open()
Dim da As New SqlDataAdapter _(
"select * from detailImg", con) Dim MyCB As SqlCommandBuilder = New SqlCommandBuilder(da)da.MissingSchemaAction = MissingSchemaAction.AddWithKey
da.Fill(ds,
"img") Dim myRow As DataRowmyRow = ds.Tables(
"img").NewRow()myRow(
"img") = MyDatads.Tables(
"detailimg").Rows.Add(myRow)da.Update(ds,
"detailimg")fs =
NothingMyCB =
Nothingds =
Nothingda =
Nothingcon.Close()
con =
Nothingbut I dont know how to update a field, can you help me one more time many thanks