Home General
New Blog Posts: Merging Reports - Part 1 and Part 2

Insert Report Archive file to Database

edited December 2003 in General
Hello,

Is it possible to load a report archive to a filestream to be saved on to a
database?

Any suggestions?

Thank you

I'm using report builder 6 standard edition.

--
Carlo

Comments

  • edited December 2003
    ---------------------------------------------------
    Tech Tip: Loading an Archive File to a Blob
    (or memory stream)
    ---------------------------------------------------

    You can easily write a routine to take a .RAF file and
    load it into a blob field or a TMemoryStream:

    myFileStream := TFileStream.Create('myArhcive.RAF', fmOpenRead);

    myFileStream.Position := 0;
    myBlobField.LoadFromStream(myFileStream);

    myFileStream.Free;


    OR

    myMemoryStream := TMemoryStream.Create;

    {note: passing 0 as the second parameter will copy the entire stream}
    myMemoryStream.CopyFrom(myFileStream, 0);

    myMemoryStream.Free;

    --
    Best Regards,

    Nico Cizik
    Digital Metaphors
    http://www.digital-metaphors.com
This discussion has been closed.