Page 1 of 1

loading time to long

Posted: Fri Dec 28, 2012 2:36 pm
by TheProfi
Hi,

we have a problem with the times to load data from a table.
We use a MS SQL 2005 Express, Delphi XE2 and TRichview 14.

The field we use to store the data is varbinary(max). The doctype is RTF because we want to print the document in a Report with Fastreport 13.3

If we put some Picture i.e. png or jpeg with sizes between 50-100 kb into the document the saving time is about ~10-30 seconds.

we have also tested with TDBRichView / TDBRichViewEdit / SRichviewEdit with direkt Dataaccess

Code: Select all

    
    Stream := TMemoryStream.Create;
    try
      RTFData := TStringlist.Create;
      RTFData.Text := aOpenPlans[aOpenPlanActiveEntry].oDataset.fieldbyname('textcontentfull').AsString;
      RTFDATA.SaveToStream(Stream);

      SRichViewEdit1.Clear;
      Stream.Position := 0;
      SRichViewEdit1.RichViewEdit.LoadRTFFromStream(Stream);
      SRichViewEdit1.Format;
    finally
      Stream.Free;
      RTFData.Free;
    end;
Do you have some ideas?

With kind regards
Georg

Posted: Fri Dec 28, 2012 7:08 pm
by Sergey Tkachenko
Does LoadRTFFromStream take all these 10-30 sec, or there are some other time consuming methods?

Please save the content of RTFData to a file and send it to me (richviewgmailcom)