Hi,

Is there a way to read a .rtf file into a textbox
I only would like te read the text without the format, without
actually opening the file.

thanx

Jans

Re: Word 2003 read rtf file into textbox by David

David
Mon Nov 26 13:41:24 PST 2007

On Nov 26, 7:44 am, jan...@hotmail.com wrote:
> Hi,
>
> Is there a way to read a .rtf file into a textbox
> I only would like te read the text without the format, without
> actually opening the file.
>
I'm not sure about 'without opening the file'. Kinda like eating a
can of pineapple without opening the can. :-)

But I digress. How about this?

Sub InsertIntoTextbox()
'David Sisson 2007

Dim rRange As Range

Set rRange = ActiveDocument.Shapes(1).TextFrame.TextRange

rRange.InsertFile FileName:="sample RTF.rtf", Range:="", _
ConfirmConversions:=False, Link:=False, Attachment:=False

rRange.Select
Selection.ClearFormatting

End Sub

Re: Word 2003 read rtf file into textbox by jans__

jans__
Mon Nov 26 14:32:00 PST 2007

On 26 nov, 22:41, David Sisson <Tinbe...@gmail.com> wrote:
> On Nov 26, 7:44 am, jan...@hotmail.com wrote:> Hi,
>
> > Is there a way to read a .rtf file into a textbox
> > I only would like te read the text without the format, without
> > actually opening the file.
>
> I'm not sure about 'without opening the file'. Kinda like eating a
> can of pineapple without opening the can. :-)
>
> But I digress. How about this?
>
> Sub InsertIntoTextbox()
> 'David Sisson 2007
>
> Dim rRange As Range
>
> Set rRange = ActiveDocument.Shapes(1).TextFrame.TextRange
>
> rRange.InsertFile FileName:="sample RTF.rtf", Range:="", _
> ConfirmConversions:=False, Link:=False, Attachment:=False
>
> rRange.Select
> Selection.ClearFormatting
>
> End Sub

I'm sorry, I wasn't very clear,
i would like to read the content of a rtf file into a textbox control
on my userform.

Re: Word 2003 read rtf file into textbox by David

David
Tue Nov 27 08:58:51 PST 2007

> I'm sorry, I wasn't very clear,
> i would like to read the content of a rtf file into a textbox control
> on my userform.

I couldn't find a way. Not without opening the file first

Sorry.