Search found 9731 matches

by Sergey Tkachenko
Tue Apr 24, 2007 9:09 am
Forum: Support
Topic: TDBRichEdit and replacing tags with text on save/load
Replies: 4
Views: 17062

OnLoadDocument is called after the document is loaded from field, but before it is displayed (i.e. before DBRichView calls Format).
In this event you can do mail merging.

DBRichView cannot save documents in fields.
by Sergey Tkachenko
Tue Apr 24, 2007 8:01 am
Forum: Support
Topic: temporarily ignoring styles
Replies: 20
Views: 70853

You can create your own item type inherited from TRVLabelItemInfo, with overriden DoPaint method.

You'll also need to assign new StyleNo to this item (please do not use values in range -201..-205, as they are reserved for new item types that will be included in the new version of TRichView ...
by Sergey Tkachenko
Sun Apr 22, 2007 11:36 am
Forum: Support
Topic: Backspace/Delete key works wrong with Korean characters
Replies: 1
Views: 9441

No, trichview does not support DBCS directly.
In order to support Korean, use Unicode: http://www.trichview.com/forums/viewtopic.php?t=70
You can still load and save DBCS files, but internally the text must be Unicode.
by Sergey Tkachenko
Sat Apr 21, 2007 9:27 am
Forum: Support
Topic: Tables and fonts..
Replies: 3
Views: 13491

Use Cell.BestWidth (and may be table.BestWidth).
They work like <td width> and <table width> in HTML.
by Sergey Tkachenko
Sat Apr 21, 2007 6:48 am
Forum: Support
Topic: Tables and fonts..
Replies: 3
Views: 13491

var table: TRVTableItemInfo;
begin
table := TRVTableItemInfo.CreateEx(1, 2, RichView1.RVData);
table.CellBorderWidth := 0;
table.BorderWidth := 0;
table.Cells[0,0].Clear;
table.Cells[0,0].AddNL('A', 0, 0);
table.Cells[0,1].Clear;
table.Cells[0,1].AddNL('B', 1, 0);
RichView1.AddItem ...
by Sergey Tkachenko
Fri Apr 20, 2007 4:34 pm
Forum: Examples, Demos
Topic: [Demo] Sending HTML email. Saving MIME-encoded files.
Replies: 40
Views: 3398906

You cannot use Indy's MIME features. Indy must think that this is a plain text e-mail.
Ok, let's assume that we have Attachments: TStringList with paths to attached files.

Modify GetEmail function (see above).
Add Stream3: TFileStream to vars.
Add the code below to the end of this function
(before ...
by Sergey Tkachenko
Thu Apr 19, 2007 4:55 am
Forum: Support
Topic: RTF via TDBRichView
Replies: 5
Views: 15095

Sorry, what do you mean?
by Sergey Tkachenko
Wed Apr 18, 2007 3:24 pm
Forum: Support
Topic: RTF via TDBRichView
Replies: 5
Views: 15095

No, TDBRichView assumes that it is linked to TBlobField.
After conversion to memo, you can use LoadCustomFormat event to display RTF files linked from this field:

procedure TForm1.DBRichView1LoadCustomFormat(Sender: TCustomRichView;
Stream: TStream; var DoDefault: Boolean);
var s: String;
begin ...
by Sergey Tkachenko
Wed Apr 18, 2007 5:47 am
Forum: Support
Topic: UTF-8
Replies: 3
Views: 12118

I was wrong.
In the latest version of RVXML, if you specify Encoding='utf-8' (character case is not important), all text (both ANSI and Unicode items) must be saved in UTF-8 encoding. If it does not happen, this is a bug, please send me document reproducing it.
If any other encoding string is ...
by Sergey Tkachenko
Wed Apr 18, 2007 4:37 am
Forum: Support
Topic: Cancel Loading RTF
Replies: 2
Views: 12543

I did not think about it... But I believe calling Abort in OnProgress must work.
by Sergey Tkachenko
Tue Apr 17, 2007 6:25 pm
Forum: Support
Topic: Change style to part of text
Replies: 6
Views: 24673

AddNL can add text in the same paragraph, pass -1 to ParaNo parameter:

Code: Select all

with table.Cells[0,0] do begin
  Clear;
  AddNL( 'aaaaaaaaaaaaaaaaaaaaa ', 7, 3);
  AddNL( cargo, 8, -1);
  AddNL( 'bbbbbbbbbbbbbbbb', 7, -1);
end;
by Sergey Tkachenko
Tue Apr 17, 2007 6:23 pm
Forum: Support
Topic: RTF via TDBRichView
Replies: 5
Views: 15095

I do not understand the question completely, but as for data type for TDBRichView/TDBRichViewEdit, it must be able to contain data of any size.
(Table.FieldByName(...) is TBLOBField) must be True for this field.

If field contains RTF document, it may be a memo field.
But by default, TDBRichViewEdit ...
by Sergey Tkachenko
Tue Apr 17, 2007 6:15 pm
Forum: Support
Topic: Removing Page break
Replies: 2
Views: 10702

Page break is not stored as character, so it cannot be found using SearchText. Page break is an item property.

If you need to remove all page breaks, and it should not be an editing operation, the code is:
for i := 0 to reText.ItemCount-1 do
reText.PageBreaksBeforeItems[i] := False;
If it must ...
by Sergey Tkachenko
Tue Apr 17, 2007 10:48 am
Forum: Support
Topic: Convert RTF to plain text
Replies: 1
Views: 9432

I recommend to create a hidden TRichViewEdit.
by Sergey Tkachenko
Tue Apr 17, 2007 10:47 am
Forum: Support
Topic: Change style to part of text
Replies: 6
Views: 24673

Why not to use several AddNLs then?