I have a SQL Server 2000 database that has a table with a text field whose
contents are in RTF format. My goal is to display this text in SSRS
reports. I have created a custom assembly to convert rtf formated text into
plain text.
Imports System.Windows.Forms
Public Class RichTextServices
Public Shared Function ConvertToPlainText(ByVal RTFText As String) As String
Dim m_rtb = New RichTextBox
m_rtb.Rtf = RTFText
Return m_rtb.Text
End Function
End Class
The assembly works great in preview mode. However, when I run the report
from my browser I get an error in the field containing the converted text.
I have copied my DLL to "C:\Program Files\Microsoft SQL
Server\MSSQL\Reporting Services\ReportServer\bin".
I have also added the attached code group to the "rssrvpolicy.config" and
"rsmgrpolicy.config" files. It still does not work.
What am I missing? Any suggestions would be greatly appreciated.
PS - If anyone knows a better way to handle RTF in SSRS that would also be
great to know. Especially if you can actually display the text with the
original formatting.
<CodeGroup
class="UnionCodeGroup"
version="1"
PermissionSetName="FullTrust"
Name="MyCodeGroup"
Description="Code group for my data processing extension">
<IMembershipCondition
class="UrlMembershipCondition"
version="1"
Url="C:\Program Files\Microsoft SQL Server\MSSQL\Reporting
Services\ReportServer\bin\myAssembly.dll"
/>
</CodeGroup>Hello Guess,
It seems the issue is caused by RichTextBox which is a com object. I wonder
if you also deploy the interop com assembly to the following folder:
C:\Program Files\Microsoft SQL Server\MSSQL\Reporting
Services\ReportServer\bin
Also, I suggest that you refer to the following article to deploy your
custom assembly in reporting service.
Deploying a Custom Assembly
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/RSPROG/htm/
rsp_prog_rdl_8mue.asp
Have a great day!
Best Regards,
Peter Yang
MCSE2000, MCSA, MCDBA
Microsoft Partner Online Support
Get Secure! - www.microsoft.com/security
=====================================================When responding to posts, please "Reply to Group" via
your newsreader so that others may learn and benefit
from your issue.
=====================================================This posting is provided "AS IS" with no warranties, and confers no rights.
| Reply-To: "Guess Nospam" <guess@.nospam.ha>
| From: "Guess Nospam" <guess@.nospam.ha>
| Subject: Custom Assembly Error
| Date: Mon, 25 Oct 2004 16:33:58 -0700
| Lines: 62
| X-Priority: 3
| X-MSMail-Priority: Normal
| X-Newsreader: Microsoft Outlook Express 6.00.2800.1409
| X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1409
| Message-ID: <O2KcisuuEHA.3376@.TK2MSFTNGP12.phx.gbl>
| Newsgroups: microsoft.public.sqlserver.reportingsvcs
| NNTP-Posting-Host: ftp.city.vancouver.bc.ca 199.175.219.1
| Path:
cpmsftngxa10.phx.gbl!TK2MSFTFEED01.phx.gbl!TK2MSFTNGP08.phx.gbl!TK2MSFTNGP12
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment