Identical to ExtractBLOB but uses an ADO recordset instead of DAO
The ADO recordset (based on a table) to store the data in
The name of the field to store the data in
The path and filename to write the binary information to.
(no description)
Dim ID As Long Dim recs As New ADODB.Recordset Dim dbs as DAO.Database Set dbs = CurrentDb() ID= 23 recs.Open "SELECT * FROM xf_tblDocStore WHERE Doc_ID=" & ID, Application.CurrentProject.Connection If recs.EOF() Then MsgBox "BLOB record not found" Else recs.MoveFirst xf.Interact.ExtractBLOB recs, "DocImage", Application.CurrentProject.path & "\Copy of Affirmative_Action.pdf" recs.Close Debug.Print "ExtractBLOB: Doc extracted to " & Application.CurrentProject.path & "\Copy of Affirmative_Action.pdf" & ": id=" & ID End If