Simon
  • Simon
  • Newbie Topic Starter
2011-09-29T09:14:21Z
Hi,

I am using the iGRichTextManager to display Rich Text in some columns on my grid.

example:
Dim fManager As iGRichTextManager
fManager = New iGRichTextManager(ig1)

fManager.ManageCol(igAll.Cols("ColumnName"))


I subsequently loop through the rows in the grid and create a tab deliminated text file which I can open in excel.

What I need is how do I get the formatted rtf to export to the file and not the actual rtf.

Hope that is clear!

Many thanks

Simon

PS. I love the igrid and have been using it for a few years now.
Igor/10Tec
2011-09-30T15:18:14Z
iGRichTextManager is a wrapper for the Windows native functionality that renders the specified RTF text (for more info, see the EM_FORMATRANGE message of the Rich Edit control), so there is no "intermediate point" where you can get the formatted text as "something" you can work with. RTF text as input -> a set of colored pixels on the screen as output, that's all.

And one more question: if you produce a tab-delimited file, it is in fact a text file, so what formatting can be stored in it?
Simon
  • Simon
  • Newbie Topic Starter
2011-10-03T06:33:24Z
Many thanks for the reponse. I dont need the formatting to be exported, just the text. As I am looping through the cells and exporting the text I thought I could identify that there is a Rich Text Box or edit control in the cell and then export just the text (without formatting) of that control instead of text for the cell. I was hoping that if this is possible you might provide me with a pointer as to how I might achieve that?

Thanks



Igor/10Tec
2011-10-03T07:38:28Z
Then you can use the functionality of the Windows Forms RichTextBox to convert RTF text to plain text.
The first search for ".net convert rtf text to plain text" on Google gave me this recipe:
How to: Convert RTF to Plain Text (C# Programming Guide)