鏂囦欢鎴栬呭浘鐗囦繚瀛樺埌鏁版嵁搴撲腑
鍙戝竷: 2008-7-15 14:50 | 浣滆: 缃戠粶杞浇 | 鏉ユ簮: 缃戠粶杞浇 | 鏌ョ湅: 33娆
鏁版嵁搴撳瓧娈碉細wjmc 鏂囦欢鍚嶏紝wjsx 鏂囦欢鐨勬墿灞曞悕銆俉jnr 鏂囦欢鐨勫唴瀹逛负浜岃繘鍒躲(鑻ccess鏁版嵁搴撲负鈥渙le瀵硅薄鈥,sql server涓衡渋mage鈥)
璇ョ▼搴忓彲浠ユ搷浣滄墍鏈夌殑鏂囦欢绫诲瀷銆
Dim Wenjian As String
Dim RD As Byte
Dim SIZE As Long
Const MYSIZE = 1048576
Dim WENJIANN() As Byte
Dim Rs As New ADODB.Recordset
Rs.Open "select * from wj", Cn, 1, 3
Rs.AddNew
Rs!wjmc = Mid(Name, 1, InStr(Name, ".") - 1)
Rs!wjsx = Mid(Name, InStr(Name, ".") + 1)
鈥榥ame涓烘枃浠剁殑鍚嶇О鍔犳墿灞曞悕
Open Filename For Binary Access Read As #1
SIZE = LOF(1)
Do While SIZE - MYSIZE >= 0
ReDim WENJIANN(MYSIZE) As Byte
Get #1, , WENJIANN
Rs!wjnr.AppendChunk WENJIANN
SIZE = SIZE - MYSIZE
Loop
If SIZE > 0 Then
ReDim WENJIANN(SIZE) As Byte
Get #1, , WENJIANN
Rs!wjnr.AppendChunk WENJIANN
End If
Close #1
Rs.Update
Set Rs = Nothing




发表于 2009-1-5 19:48
| 











