回复 7楼 ZHRXJR
Private Sub Command6_Click()
Dim conn As New ADODB.Connection
Dim rs As New ADODB.Recordset
Dim stm As New ADODB.Stream
'Set conn = New ADODB.Connection
'Set rs = New ADODB.Recordset
'Set mstream = New ADODB.Stream
conn.Open Connstring
rs.Open "select * from ver", conn, adOpenKeyset, adLockOptimistic
CommonDialog1.Filter = "*.*"
CommonDialog1.ShowOpen
Text7.Text = CommonDialog1.FileTitle
'Set stm = New ADODB.Stream
'Set stm = CreateObject("ADODB.Stream")
With stm ------
按照方法在这个地方出现同样的错误提示!
.Type = adTypeBinary
.Open
.LoadFromFile CommonDialog1.FileName
End With
If rs.RecordCount = 0 Then
rs.AddNew
rs.Fields(1) = 1#
rs.Update
End If
rs.Fields(0) = mstream.Read
rs.Fields(1) = CommonDialog1.FileTitle
rs.Update
mstream.Close
End Sub