Wrox Programmer Forums
|
BOOK: Professional SQL Server Reporting Services ISBN: 0-7645-6878-7
This is the forum to discuss the Wrox book Professional SQL ServerReporting Services by Paul Turley, Todd Bryant, James Counihan, George McKee, Dave DuVarney; ISBN: 9780764568787
Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: Professional SQL Server Reporting Services ISBN: 0-7645-6878-7 section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old June 17th, 2004, 08:55 AM
Authorized User
 
Join Date: Jun 2004
Posts: 50
Thanks: 0
Thanked 0 Times in 0 Posts
Default Using A Custom Assembly, chap 5 p154 - 155

On page 154 the book tells me to un-comment code in the RSReportDesigner.Config and the RSReportServer.config

Since I did not have this code block in either file I added it. I may or may not have put it in the correct place ( I put the code as the last item inside the outermost set of tags ).

I created a new class project which I called Report_Formats in which there is a class (also called report_Formats). I then went through the steps as outlined on page 155 to add the reference to the compiled dll (which I put in the reporting services bin as directed).

I ended up with an assembly reference like this:
=Report_Formats.Report_Formats.CustomFormat(Fields !Phone.Value, "Phone")

When I click the preview tab I get an error:
c:\sinotification\report project2\CustomCodeInReport.rdl Error while loading code module: ‘Report_Formats, Version=1.0.1629.14027, Culture=neutral, PublicKeyToken=null’. Details: File or assembly name Report_Formats, or one of its dependencies, was not found.

I don't know if this is because of an error in the class (I don't think it is) or if the code I added to the XML config files is either incorrect (it is exactly as in the book) or in the wrong spot.

Microsoft may have made other changes between the beta (which the book is based on) and my version.

Can anyone help me find what the problem is??



Sandy Murdock MCP
__________________
Sandy Murdock MCP
 
Old June 17th, 2004, 09:21 AM
Authorized User
 
Join Date: Jun 2004
Posts: 50
Thanks: 0
Thanked 0 Times in 0 Posts
Default

I have it working but I can't believe that I am doing it the correct way.

I found a reference via microsoft:
http://msdn.microsoft.com/library/de...g_rdl_8mue.asp

which mentioned that the custom dll could be put in EITHER the server directory as noted in the book:
c:\Program...\ReportingServices\ReportServer\bin
or
C:\Program Files\Microsoft SQL Server\80\Tools\Report Designer

When I put the dll in the ReportServer\bin I could not preview the report. I dropped an additional copy into the Report Designer directory and it now works.

Also of note: According to microsoft if you change your class code and recompile you will have to go into each report and update your reference.

I want someone to tell me that I only need to put my class files in one place and maintain them in one place. Anyone?




Sandy Murdock MCP
 
Old June 20th, 2007, 05:01 PM
Registered User
 
Join Date: Jun 2007
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Yes.
First, you are right. You need the assembly (.dll) file to reside in BOTH places (one for VS designer to work and the other for the report deployed to Reporting Services to work).

And yes, you do NOT need to redeploy the assembly every time you change the report that calls it. You only need to re-deploy the assembly if it changes. When you do change it, be sure to NOT change the Version or you will have to update the reports that use it to refer to the assembly with the new version number.








Similar Threads
Thread Thread Starter Forum Replies Last Post
custom PKIXCertPathChecker (chap 7) rayback_2 BOOK: Beginning Cryptography with Java 3 July 24th, 2008 02:13 AM
Web Service, Custom Control, Custom Return Type robzyc ASP.NET 2.0 Basics 6 June 10th, 2008 08:03 AM
Converting .NET 2.0 Assembly to .Net 1.x Assembly pskaushik .NET Framework 2.0 1 November 25th, 2006 01:51 PM
P154 DesC BOOK: Beginning Visual Basic 2005 ISBN: 978-0-7645-7401-6 4 November 9th, 2006 12:04 PM
Sending E-Mail from custom assembly nsrujan C# 0 February 6th, 2006 10:08 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.