WPCubed Product Support

StringGrid / Clipboard as paragraph

Hi !

Can anyone give me some informations how to add a stringgrid as a new paragraph?
Some stringgrids have a copytoclipboard methode but I think that´s not a good way.

And second question ...
How can I add the contense of the clipboard as a new paragraph?

#1 ♥ 0
5.2k Views 2 users read 1 min

Hello !

Has nobody here a solution for this problem?

I´ve done some search here but can´t find anything regarding stringgrids.
For clipboard I found some code, but it don´t show how to insert this as a new paragraph.

Any help would be great :roll:

#2 ♥ 0
support

Hi,

Use TableAdd with the count of cols/rows of your grid and in the callback read the value from the grid.

Julian

#3 ♥ 0

Hi Julian!

Thx for the TableAdd tip. I got it working 🙂

So at the Moment there is only one question left ...
How can I add the clipboard to a new paragraph?
Or does

RTF.PasteFromClipboard

paste the clipboard directly as new paragraph?

#4 ♥ 0
support

Hi,

you can convert the clipboard into a stream and use TParagraph.LoadFromStream. If that is just ANSI text use par.SetText instead.

PasteFromClipboard pastes text as one or more paragraphs.

Julianh

#5 ♥ 0
This category is archived. No new posts are possible.