By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
464,668 Members | 1,361 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 464,668 IT Pros & Developers. It's quick & easy.

Crystal RTF question with VB.Net

P: n/a
Hi,

I am trying to get a rich text box to display some text in rich text
format and am having a very difficult time getting it to work properly.
Here is what I am doing...

I have created a crystal report that only has the field (called Memo1)
that I want to display. I set the TextFormat property of the field to
crRTFText (and I also made sure that the "Text Interpreter" under the
Paragraph tab of the Format menu was also set to "RTF Text").

The text I want to display is saved in an Access DB, already in rich
text format. I am connecting to the db using ADO.NET and am able to
populate the corresponding field on my crystal report. The problem is
that when the report displays, it is showing all of the rich text code
rather than the text formatted as such.

I also tried to put a Text Object on my report and drag the Memo1 field
into it, but that did not work either as I got the same result.

This is really driving me up the wall, and I will be very grateful if
anyone is able to help me with this issue. Thank you very much!

--Matt

Nov 21 '05 #1
Share this Question
Share on Google+
2 Replies

P: n/a
Matt,

There is a VB6 control 'richtx32.ocx'. You can add this from references
'COM' objects.

HTH,

Phil
"GatorBait" <MP****@gmail.com> wrote in message
news:11*********************@g43g2000cwa.googlegro ups.com...
Hi,

I am trying to get a rich text box to display some text in rich text
format and am having a very difficult time getting it to work properly.
Here is what I am doing...

I have created a crystal report that only has the field (called Memo1)
that I want to display. I set the TextFormat property of the field to
crRTFText (and I also made sure that the "Text Interpreter" under the
Paragraph tab of the Format menu was also set to "RTF Text").

The text I want to display is saved in an Access DB, already in rich
text format. I am connecting to the db using ADO.NET and am able to
populate the corresponding field on my crystal report. The problem is
that when the report displays, it is showing all of the rich text code
rather than the text formatted as such.

I also tried to put a Text Object on my report and drag the Memo1 field
into it, but that did not work either as I got the same result.

This is really driving me up the wall, and I will be very grateful if
anyone is able to help me with this issue. Thank you very much!

--Matt

Nov 21 '05 #2

P: n/a
Phil,

Thank you very much for your response. I was able to find the
reference you mentioned and I added it to my project and I have a
feeling that there is more that I need to do. I'm a newbie to .NET,
I've only been using it for about a month now, can you please give me
some more details on what else I need to do? Here is the code I am
using:

Dim conStr As String = "Provider=Microsoft.Jet.OLEDB.4.0;Data
Source=C:\QuickFL\QFWindata.mdb"
Dim conn As OleDbConnection = New OleDbConnection(conStr)
Dim sqlStr As String = "SELECT " & _
"*" & _
"FROM " & _
"Letters " & _
"WHERE " & _
"Client_ID = 1141751058"
Dim da As OleDbDataAdapter = New OleDbDataAdapter(sqlStr, conn)
Dim ds As DataSet = New DataSet()
Dim rpt As New Letter()

da.Fill(ds, "tLetters")

rpt.SetDataSource(ds.Tables("tLetters"))
fReportViewer = New ReportViewer()
fReportViewer.crvMain.ReportSource = rpt
fReportViewer.MdiParent = Me.MdiParent
fReportViewer.Show()

Thanks again!

Nov 21 '05 #3

This discussion thread is closed

Replies have been disabled for this discussion.