我用的是下面的方法保存的,可就是不知道为什么以后从数据库中取出来的时候变成了乱码。
var BS:TADOBlobStream;
begin
ADOQuery.Edit();
BS:=TADOBlobStream.Create(TBlobField(ADOQuery.FindField('DocFile')),bmWrite);
  try
    If OLEContainer1.State<>osEmpty then
      OLEContainer1.SaveToStream(BS);
  finally
    BS.free;
  end;
ADOQuery.Post();
end;

解决方案 »

  1.   

    我是按照下面的代码读的:
    with DM.ADODocList do
    begin
          DocFile:=ExtractFilePath(Application.ExeName)+FieldValues'DocTypeFileName']+FieldValues['DocID']+FieldValues['DocType'];//临时文件名
          with TADOBlobStream.Create(TBlobField(FindField('DocFile')), bmRead) do
          begin
            if Size<>0 then
              SaveToFile(DocFile);
            Free;
          end;
    end;
    OLEContainer1.DestroyObject();
    OLEContainer1.CreateObjectFromFile(DocFile, False);  //取文档
    OLEContainer1.DoVerb(ovShow);