OK still getting closer. My com interface works, but the SQL inside the dot net dll doesnt. Here is what I have so far that results in the error :
"Dynamic SQL generation for the UpdateCommand is not supported against a SelectCommand that does not return any key column information."
Does that mean the query has to return a Key column?
by the way the code in the previous post put the bytearray into the db , but it put it into a new row which isnt what i wanted. therefore I think the answer to the quedtion about key column above is no?
Code:Dim da As New SqlCeDataAdapter(strSQL, strCon) Dim ds As New DataSet() Dim cb As New SqlCeCommandBuilder(da) Dim row As DataRow da.Fill(ds) Dim arr() As Byte ReDim arr(FileLen(strSourceFile) - 1) FileOpen(1, strSourceFile, OpenMode.Binary, OpenAccess.Read, OpenShare.Shared) FileGet(1, arr) FileClose(1) ' row = ds.Tables(0).NewRow row = ds.Tables(0).Rows(0) row.Item(0) = arr ds.Tables(0).Rows(0).Item("myColumn") = arr da.Update(ds)




Reply With Quote