SQL Server Forums
Profile | Register | Active Topics | Members | Search | Forum FAQ
 
Register Now and get your question answered!
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 Development Tools
 Reporting Services Development
 Reference Custom Assembly in SSRS 2008
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

Avdhut
Starting Member

India
11 Posts

Posted - 04/10/2012 :  03:07:36  Show Profile  Reply with Quote
Hi,
I am using SSRS 2008, I want to add reference to custom assembly.
For that,
1)I had created a Visual Studio 2010 Class Library project.In that i had created a class called Utilities with following code,

Imports System
Imports System.Collections.Generic
Imports System.Text
Imports rsCustomAssembly

Public Class Utilities
Public Function Concat(ByVal string1 As String, ByVal string2 As String) As String

Return string1 + " " + string2
End Function
End Class






2)Then written a function and build that apllication.
3)Then I copied the .dll file to,

C:\Program Files\Microsoft Visual Studio 9.0\Common7\IDE\PrivateAssemblies
And

C:\Program Files\Microsoft SQL Server\MSRS10.MSSQLSERVER\Reporting Services\ReportServer\bin

4) Also I had Added the followind code to rssrvpolicy.config file,where rsCustomAssembly is my .dll file name

<CodeGroup class="UnionCodeGroup" version="1" PermissionSetName="FullTrust" Name="rsCustomAssembly" Description="reportHelperLib. ">
<IMembershipCondition
class="UrlMembershipCondition"
version="1"
Url="C:\Program Files\Microsoft SQL Server\MSRS10.MSSQLSERVER\Reporting Services\ReportServer\bin\rsCustomAssembly.dll"
/>
</CodeGroup>

5) Then I Had added the textbox to my report and gave exprn as,

=rsCustomAssembly.Utilities.Concat("Reporting","Services")
But,Still I am Getting the Following Error ,

i)[rsErrorLoadingCodeModule] Error while loading code module: ‘rsCustomAssembly, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null’. Details: Could not load file or assembly 'rsCustomAssembly, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null' or one of its dependencies. The system cannot find the file specified.

ii)[rsCompilerErrorInExpression] The Value expression for the textrun ‘Textbox4.Paragraphs[0].TextRuns[0]’ contains an error: [BC30451] Name 'rsCustomAssembly' is not declared.


Please help me in this scenario.
I am waiting eagarly for the reply.
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
SQL Server Forums © 2000-2009 SQLTeam Publishing, LLC Go To Top Of Page
This page was generated in 0.08 seconds. Powered By: Snitz Forums 2000