要用GetChunk方法你可以到我主页上下载一个例子http://www14.brinkster.com/Media2DB.zip

解决方案 »

  1.   

    這是我自己的一個實例,只不過是VBScript的,不知有沒有用,你可以參考一下: sub DownLoadFileFromImage()
       Set AdoDocumentRs = createobject("ADODB.Recordset")
       AdoDocumentRs.CursorLocation = 3
       AdoDocumentRs.CursorType =2
       AdoDocumentRs.LockType = 1
       AdoDocumentRs.Open SQLstr, objADOConnect   Set AdoStream = createobject("ADODB.Stream")
       AdoStream.Type = 1
       AdoStream.Open
       AdoStream.Write AdoDocumentRs.Fields("ImageColumn").Value '請注意這裡   InKey = InputBox("請輸入檔案的存檔路徑")
       if InKey ="" then
         msgbox "you is not input"
         exit sub
       end if
     
       AdoStream.SaveToFile InKey & "\" & TmpFileName' 請注意這裡   AdoDocumentRs.close
       adostream.close
       set AdoDocumentRs=Nothing
       set AdoStream=Nothing
    end sub