storing a word doc in a blob field

ziller

Member²
hello,

i'm using oracle 7.3.4 and i've created this table :

TMP (filename varchar2(50), word_doc long raw)
It works great with BDE but with DOA, each time i try to save my word document (wich is in an olecontainer) i get an error on the TBlobStream.Create function.

here is my code :

procedure TForm2.Button1Click(Sender: TObject);
var
oStream : TBlobStream;
begin
oStream := nil;
if Word.State osEmpty then
try
oStream := TBlobStream.Create(
TBlobField(form1.tb_ACT_TMP.FieldByName('WORD_DOC')),bmReadWrite);
Word.SaveToStream(oStream);
ShowMessage('Document Word enregistr
 
The TBLOBStream class is only compatible with TBDEDataSet descendants. The TOracleDataSet is a TDataSet descendant. You can use the TBLOBField.SaveToStream method instead.

------------------
Marco Kalter
Allround Automations
 
Back
Top