RTF from Oracle To VB

O

O.B.1.

Hi all,

Is there a way to convert RTF indications to VB/Word
from an oracle SQL-select?

This is the an example of a string returned from oracle:
"{BR2}textgoeshere{BR1}paragraph goes here{BR1}again some
text" etc etc
The oracle guy at my company says this is RTF text.
Does anyone know how to interprete this in VB, so that it
can be sent to word-document, preserving the formatting
of carrige returns etc? Thanks in advance!
Regards, O.B.1.
 
H

Helmut Weber

Hi,
create a very small word-document, save it as *.rtf,
rename it to *.txt and open it with an Editor, e.g.
Notepad. Then you get an idea what RTF is like.
To parse a string, if one knew, what substrings
have what meaning, is a very simple thing to do
with VBA.
Greetings from Bavaria, Germany
Helmut Weber
"red.sys" & chr$(64) & "t-online.de"
Word 97, NT 4.0
 
G

Guest

Do you know any links that could contain more information
on this matter? Or an example to get me going could be
handy as well.
 
H

Helmut Weber

Hi,
if {BR1} means, "start of text" you replace it with
nothing, if {BR2} means "paragraph" you replace it
with chr$(13) or vbcrlf or vbcr, if {BR3} would mean
"new line" you replace it with chr$(11) or vblf.
The thing is, to find out, what these strings mean.
Doesn't look like rtf to me. To google for rtf or
rtf-specifications should return more information
than you can handle.
Greetings from Bavaria, Germany
Helmut Weber
"red.sys" & chr$(64) & "t-online.de"
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top