Custom Assembly Class Not Defined
Jan 19, 2006
I have a custom assembly that i'm trying to get tied into my report. the problem is when i try to call it i get the error that the class is not defined
I have the class in the references tab and the class name and instance name both have a name.
here's the error I'm getting
Error 1 [rsCompilerErrorInClassInstanceDeclaration] Error in class instance declaration for class Assembly_1: [BC30002] Type '[ClassName]' is not defined. [Project folder][reportname].rdl 0 0
View 6 Replies
ADVERTISEMENT
Mar 16, 2007
I have several fuctions that I would like to share between my different script tasks in my SSIS package. I assume I do this by creating a custom class, but I cant quite figure it out. Can someone please point me in the right direction?
Thank You!!
View 4 Replies
View Related
Nov 27, 2006
Hello everybody,
I am new to .NET programming and the C# language. I'm coming from a ColdFusion/Java background, but am trying to learn .NET to further my abilities as a programmer, and take advantage of the CLR functionality in SQL Server.
What I am wondering is: is it possible to write an assembly which has stored procedures and functions that each utilize a custom class written within that assembly?
I am having some trouble with this concept. I am writing a UDF that will compile various data together and build a string from it. To help simplify the code, I want to build a custom class which will represent the primary object I am running the compilations against.
I would like to have the class be able to load its data directly from the database using a load() method. However, I am getting the following error when trying to run the UDF:
Msg 6522, Level 16, State 2, Line 1
A .NET Framework error occurred during execution of user defined routine or aggregate 'CompileList':
System.Security.SecurityException: Request for the permission of type 'System.Data.SqlClient.SqlClientPermission, System.Data, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089' failed.
System.Security.SecurityException:
at System.Security.CodeAccessSecurityEngine.Check(Object demand, StackCrawlMark& stackMark, Boolean isPermSet)
at System.Security.PermissionSet.Demand()
at System.Data.Common.DbConnectionOptions.DemandPermission()
at System.Data.ProviderBase.DbConnectionClosed.OpenConnection(DbConnection outerConnection, DbConnectionFactory connectionFactory)
at System.Data.SqlClient.SqlConnection.Open()
at vtrenz_listmanager_package.lib.iMAList.load()
at UserDefinedFunctions.CompileList(Int32 ownerid, Int32 userid, Int32 listid)
Any help and/or insight would be greatly appreciated.
Thanks,
JD
View 6 Replies
View Related
Jun 9, 2006
I have OLE DB Connections set up in my connection manager (Native OLE DBMicrosoft OLE DB Provider for SQL Server). I would like to reference and query these connections from a custom task, written in C#. I currently reference it as follows:
using System.Data.OleDb;
...................................
OleDbConnection connection = (OleDbConnection) connections["MyConnection"].AcquireConnection(null);
What may be obvious to some (though wasn't to me, as I am new at this), when I run the task, I get an error saying that I cannot make this cast. After perusing the boards, I understand that this is because I am not making a cast to the right connection type. Well, that is where I am lost. What connection type (and corresponding library) do I need to reference? I want to continue to use the "Native OLE DB..." connection.
Thanks!
View 3 Replies
View Related
Feb 26, 2008
Hi,
I'm trying to do something rather weird, but I really need it. I'm trying to launch a SSIS package from a report
I built a custom assembly with one method that loads a package from file and then executes it. The assembly works fine.
I added the custom assembly to the report properties, instantiated the class in the assembly (the method is not static), called the method from the report (a textbox renders the string return value from the method).
I added the
Code Snippet[assembly: System.Security.AllowPartiallyTrustedCallers]
attribute to the AssemblyInfo.cs file
Created the strong name for the assembly.
Got the PublicKeyBlob with ILDASM, used it to add a new CodeGroup with the "StrongNameMembershipCondition" in the policy configuration files of ReportDesigner (RSPreviewPolicy.config), ReportServer (rssrvpolicy.config) and ReportManager (rsmgrpolicy.config).
Copied the dll in the bin folders of ReportServer and Visual Studio PrivateAssemblies.
I keep getting the awfull #Error message on the report when viewing it from ReportManager or ReportServer (in preview mode in VisualStudio all is well because security is not applied to user code).
I tried debugging:
- created a solution with two subprojects, one is the report, the other one is the assembly
- marked the report as the Startup Item
I get a SecurityException in debug and debuglocal modes when I try to instantiate a SSIS package.
Code SnippetPackage = new Package();
While digging in the exception call stack, it turns out I lack a permission for accessing unmanaged code (the source assembly of the exception is mscorlib). Also in the ouput window, while starting debugging i see a lot of SystemArgument exceptions in mscorlib.
I am perfectly aware that in order to be able to launch a SSIS package from code I referenced Microsoft.SqlServer.DtsRuntimeWrap.dll, so in desperation I added another CodeGroup in the aforementioned config files for this dll (StrongNameMembershipCondition) and copied the assembly in the deployment folders.
1: I would really like to know how to get the whole thing working. I find rather strange that even though I set the FullTrust
PermissionSet for my assembly (and the Microsoft.SqlServer.DtsRuntimeWrap assembly) I keep getting security exceptions.
While exploring the web for help I saw I need to assert all individual permissions for every restricted resource I'm accessing in the custom assembly, problem is I don't know exactly which ones I'm accessing and, being new to .NET security, I don't know how.
Surely I need to assert a file IO permission to load the package from file, a sqlclientpermission if I am accessing SqlServer in the package, and perhaps a unmanagedcode permission, given the the exception I described earlier (perhaps the Microsoft.SqlServer.DtsRuntimeWrap assembly is not managed code or is accessing some other unmanaged assembly).
Again, I wouldn't know how.
...and last
2: I tried modifying the assembly to only load a string from a file.. I had some problems with security but I got it working once, but I haven't figured out how exactly 'cause when fiddling around to understand things, I lost the working configuration. Really stupid, I know....
While testing this version of the assembly I followed an advice I found on some blog and restarted IIS and Reporting Services system service..
Is this always necessary after modifying the assembly source ? Do I need to restart every time both IIS AND Reporting Services
I would really appreciate every bit of help or advice anyone has to offer.
Thanks in advance.
View 6 Replies
View Related
Jan 22, 2008
Hello experts,
I need some help please.
Yesterday I get the answer that I had to use an assembly if I would like to use a function as global. Right now I€™m very desperate because my VS didn€™t recognize my DLL.
I get the error: "Could not load file or assembly .....The system cannot find the file specified."
After red the threads I tried to use gacutil.exe to add my assembly to the cache.
This action fails with the error:€? Failure adding Assembly to cache. Attempt to install an assembly without a strong name.€?
After that I tried to build a strong name through the follow execute:
Sn €“Vr ClassLibrary.dll. This action fails too. I get the follow Error description: €œdll does not represent a strongly named assembly€?.
What made me wrong?
Is there an easier workaround?
Have someone a good Idea could help me?
Hope to hear you soon.
Best regards,
Alex
View 4 Replies
View Related
Nov 27, 2007
Hi,
I was wanting to get some data through a custom assemly. I can successfully return a primitive data type such as a string and put it in a textbox, but I really need to return more data, and possibly bind it to a Table.
For example, maybe I could return from the call a Dataset and bind it as a DataSource which then can be bound to a Table, or maybe a array of string.
Is this possible? If so, are there any good examples that you know of?
Thanks,
AussieGuy
View 1 Replies
View Related
Apr 6, 2006
Hi there
I am trying to integrat a custom assembly into a ssis-package. I copy the assembly into the framwork folder (v2.0.50727) add the reference, use the assembly everything fine. When I try to debug I get a message stating that the assembly name, version .... cannot be found. I tried to do that with signing and without - not difference.
Am I missing something?
Please help
View 3 Replies
View Related
Oct 28, 2005
I've created C# assembly which was included into Script Task code as following:
View 10 Replies
View Related
Jan 7, 2008
When I add a custom assembly
I am trying to pass certain fields in dataset I am getting the following error
invalid fields i.e. that is fields that I passed are invalid.
It also says multi path identifier for microsft.reportingservices.reportobjectmodel.fieldimpl cud not be found.
Thanks
Sai
View 1 Replies
View Related
Oct 3, 2007
Hello Everyone,
When I run my report from report manager, I get the following error message
Failed to load expression host assembly. Details: Request for the permission of type 'System.Security.Permissions.FileIOPermission, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089' failed.
My report uses a custom assembly. I have already done the following
1. copied the assembly in the "reportserverin" and the "common 7privateassemblies" area
2. Made the following entry in the rssrvpolicy.config
<CodeGroup
class="UnionCodeGroup"
version="1"
PermissionSetName="FullTrust"
Name="RSUtil.TranslationHelper"
Description="Translation Helper Utility">
<IMembershipCondition
class="UrlMembershipCondition"
version="1"
Url="C:Program FilesMicrosoft SQL ServerMSSQL.5Reporting ServicesReportServerinAMOTest.dll"
/>
</CodeGroup>
3. Added the following line to my assemblyinfo.cs file
[assembly: AllowPartiallyTrustedCallers]
regards,
Abhishek.
View 9 Replies
View Related
Feb 28, 2008
I have developed a custom assembly to render a signature from an array of bytes in an SSRS Image control. The assembly works perfectly in the designer. It is strong-named and has the AllowPartiallyTrustedCallers attribute applied to it; I have deployed the assembly to the "%SQL SERVER%MSSQL.3Reporting ServicesReportServerin" folder; given it fulltrust permissions in the rssrvpolcy.config file; made sure that the NTFS file security is correct; and the assembly just doesn't appear to be called. The assembly doesn't execute when I use the "F5" popup preview mode on my development machine, either.
I don't get any error messages in the report, I just don't get any image output, either. The rest of the report elements render correctly. Of course, the SSRS log files are useless. Enabling the Verbose trace switch doesn't yield any useful information, I don't think, except that in the lines pertaining to running my signature-enabled report there are no mentions of even attempting to use my custom assembly.
I have attempted to enable object access auditing (both success and failure) to determine if my assembly is even being accessed by SSRS and there are no audit messages in the Security Event log.
Can anyone offer any other troubleshooting suggestions?
Thanks,
Matthew Belk
View 3 Replies
View Related
Aug 15, 2006
Good Morning..
We're having a heck of a good time trying to implement our first CDE project in SSRS 2005.
In our SDE class library we have included an App.Config file where we want to store configuration settings..
Trouble is that when we view the configuration settings or connection string settings in debug mode, they're not being read for some reason..
Here's our app.config file:
-------------------------------------------------------------
<?xml version="1.0" encoding="utf-8" ?>
<configuration>
<configSections>
</configSections>
<appSettings>
<add key="eventLogName" value="FocusDPEEventLog" />
</appSettings>
<connectionStrings>
<add name="PassConnString" connectionString="Data Source=SOMEDATASOURSE;Persist Security Info=True;User ID=SOMEUSERNAME;Password=SOMEPASSWORD;Unicode=True"
providerName="System.Data.OracleClient" />
</connectionStrings>
</configuration>
-------------------------------------------------------------
Here's what our Immediate window Debugger is tellin' us about our configuration settings:
-------------------------------------------------------------
ConfigurationManager.AppSettings
{System.Configuration.KeyValueInternalCollection}
[System.Configuration.KeyValueInternalCollection]: {System.Configuration.KeyValueInternalCollection}
base {System.Collections.Specialized.NameObjectCollectionBase}: {System.Configuration.KeyValueInternalCollection}
AllKeys: {Dimensions:[0]}<----incorrect should be 1
ConfigurationManager.ConnectionStrings
Count = 1 <----ok, is one, but the wrong 1, see 3 lines down...
base {System.Configuration.ConfigurationElementCollection}: Count = 1
ConfigurationManager.ConnectionStrings[0]
{data source=.SQLEXPRESS;Integrated Security=SSPI;AttachDBFilename=|DataDirectory|aspnetdb.mdf;User Instance=true}<--Should be PassConnString
base {System.Configuration.ConfigurationElement}: {data source=.SQLEXPRESS;Integrated Security=SSPI;AttachDBFilename=|DataDirectory|aspnetdb.mdf;User Instance=true}
ConnectionString: "data source=.\SQLEXPRESS;Integrated Security=SSPI;AttachDBFilename=|DataDirectory|aspnetdb.mdf;User Instance=true"
Name: "LocalSqlServer"
ProviderName: "System.Data.SqlClient"
Now notice the stuff in bold...I have NO IDEA where this gosh-danged thing is reading, but it doesn't seem like it's the app.config file in our class library...
thanks..
Doug
View 1 Replies
View Related
Mar 28, 2008
i deigned assembly and referced it to my report in preview
when deployed the report , i get #Error
i don't add any cas code.
pls help
View 4 Replies
View Related
Oct 8, 2015
I have build a vb.net class that uses the AxMetadataServiceClient (MS Dynamics Axapta model store) this class works like expected in .net app.When I try to create this assembly in sql it fails with this error
Msg 10300, Level 16, State 2, Line 6
Assembly 'System.EnterpriseServices' references assembly 'System.EnterpriseServices, version=4.0.0.0, culture=neutral, publickeytoken= b03f5f7f11 d50a3 a.', which is not present in the current database.
SQL Server attempted to locate and automatically load the referenced assembly from the same location where referring assembly came from, but that operation has failed (reason: version, culture or public key mismatch). Please load the referenced assembly into the current database and retry your request.can't create the assembly since it references it self and can't find it self ?
View 3 Replies
View Related
Mar 25, 2008
I have a custom assembly that I'm trying to use with my resport in Reporting Services in SQL Server 2008.
I keep consistently getting a "Request for the permission of type 'System.Data.SqlClient.SqlClientPermission, System.Data,Version=2.0.0.0, Culture=neutral,PublicKeyToken=b77a5c561934e089' failed" error. Even in preview mode.
- I added <Assembly: AllowPartiallyTrustedCallers()> attribute to the assembly
- I'm asserting the permission in the routine that is doing the database call with the follwing lines:
Dim permission As SqlClient.SqlClientPermission = New SqlClient.SqlClientPermission(PermissionState.Unrestricted)
permission.Assert()
- I went in .net 2.0 Framework configuration and made the assembly fully trusted
- I added the approprtiate codegroup to the rssrvpolicy.config file
- I tried the same assembly on another PC running SQL server reporting services 2005, its working just fine.
what is it that I am missing?
View 1 Replies
View Related
Jan 7, 2008
Hi,
I use vs2005 and ssrs 2005.
I have an assembly like
namespace PackageCode
{
public static class Class1
{
public static string GetRequired(bool Split, string Id_StockItem, string InventoryUpdateQuery, string TotalRequired)
{
string outText = "";
return "Test"
...........
I did the
reportViewer.LocalReport.AddTrustedCodeModuleInCurrentAppDomain
(€?PackageCode, Version=1.0.0.0, Culture=neutral, PublicKeyToken=6d1c15bd232054a1€?);
part in my code.
I also added the
[assembly: System.Security.AllowPartiallyTrustedCallers]
too.
I published the assembly to GAC.
I added the dll as reference in rdlc file.
And I get this error when I try to enter this code under a textbox
=PackageCode.Class1.GetRequired(CBOOL(Fields!Split.Value),CSTR(Fields!StockItem),.....)
GetRequired is underlined with a red error line which says "unrecognized identifer" when I mouseover onto it.
And when I run the report I get #Error in that textbox.
I dont have a reporting server.I get the data from a dataset.
What to do now ?
Thanks for help.
View 4 Replies
View Related
Jan 10, 2007
Is it possible to have a Reporting Services dataset be returned from a custom assembly? I need to produce data for a graph that is not easily queried from the database and I am already familiar with using a custom assembly in an RS report.
What I would like to do is have a method that fills a dataset and returns it to the report for processing. Is this possible?
I am running SQL 2000 and RS 2000.
Thanks.
View 4 Replies
View Related
Sep 20, 2007
OK. I created a few functions in a Public Class called SSRSFunctions. I built it and deployed it to my desktop. What do I do now? Can it be included as standard functions in the function list within SSRS? Do I add a reference to the Class at the solution level? At the report level? If all I do is add a reference at the report level, I may as well add the functions to each report's code window, which is what I have been doing. I'd at least like to add a single reference to my solution if I can't get it added to the function list.
Thanks!
View 13 Replies
View Related
May 17, 2007
I have created a custom assembly and referenced it and the program builds successfully. When I try to run the report in design mode, it will not render, it throws an exception when it tries to create a PDF. When I remove the assembly, the reports work well. So I'm not sure what it is that I'm doing wrong - does anyone have any suggestions?
namespace Calculations
{
public class calcPercentage
{
public static decimal Percentage(decimal decValueOne, decimal decValueTwo)
{
decimal decPercentage = 0;
if (decValueOne == 0 || decValueTwo == 0)
{
decPercentage = 0;
}
else
{
decPercentage = (decValueOne - decValueTwo) / decValueOne;
}
return decPercentage;
}
}
}
Then in my textbox I put:
=Calculations.CalcPercentage.Percentage(SUM(Fields!PreviousYTDExpenseAmount.Value, "Template_OutputData_Sales"), SUM(Fields!PreviousYTDExpenseAmount.Value, "Template_OutputData_CGS"))
I referenced the assembly and added it to C:Program FilesMicrosoft Visual Studio 8Common7IDEPrivateAssemblies and I still get that error message so I do not know what the problem is.
The line where the exception occurs happens here:
byte[] bytes = MyReport.rvOutput.LocalReport.Render("PDF", null, out mimeType, out encoding, out extension, out streamids, out warnings);
Thanks so much for you help! If you have any suggestions about my next error...i'm all ears!
View 7 Replies
View Related
Jun 30, 2006
Hi,
Can anyone tell me where I might find the Class and Sequence Diagrams for the SSIS framework (for Custom Components)?
I've just started trying to create some Custom Transform Components and
I'm really struggling to get my head around the component lifecycle
(i.e what methods are called when, with what arguments, and why) with
just the BOL documentation to guide me.
Thanks in advance,
Lawrie
View 1 Replies
View Related
Jun 11, 2015
I have a requirement in which i have to create a custom .net class library for Ex:-I retrieve password(s) from a thrid party component. Below is what i am doing.
(1) Created a custom class library which reads a custom .xml file from a drive Ex:- "D:MyAppMYAppCofig.xml" and sets to my properties of my custom class library and inside it i created an instance of third party component's class and passed these values. Since i need to use this .net custom class library both in web and ssis/database side i am using this custom .xml file.
(2) After validating passed data (properties set in custom .net class library) the thrid party component instance object created in my custom .net class libraty returs a password to me own custom .net class libray.
(3) This password I use in my web app for connecting to database. This code is working fine.
(4) My question is how to execute a custom .net class library code through ssis and to use the my same custom .net class library and pass the password to my SSIS component / taks so that that code block also uses the returned password to connect and do any needed tasks? In other words how to use custom .net class library from SSIS.
My Environment is as follows:-
SQL Server is : 2008 R2
VS.NET 2013
View 5 Replies
View Related
Feb 13, 2008
Good morning all,
Due to "security considerations", the company I am currently working with does not want me deploying custom assemblies into
Microsoft SQL ServerMSSQL.3Reporting ServicesReportServerin.
They have created a subdirectory:
Microsoft SQL ServerMSSQL.3Reporting ServicesReportServerinmySubDirectoryName
Unfortunately, I can't get my report to see the dll when it's in the subdirectory. Is there any way to do this?
Thanks,
Kathryn
View 1 Replies
View Related
Mar 29, 2008
I designed dll file to get data from sql server, i am calling the dll from ssrs 2005
in preview , everything is ok but after deploying and put the dll file in C:Program FilesMicrosoft SQL ServerMSSQL.3Reporting ServicesReportServerin and add this to rssrvpolicy.config
<CodeGroup
class="SqlClientPermission"
version="1"
Name="MySecurityExtensionCodeGroup"
Description="Code Group for Don's test security extension"
PermissionSetName="FullTrust">
<IMembershipCondition
class="UrlMembershipCondition"
version="1"
Url="C:Program FilesMicrosoft SQL ServerMSSQLReporting
ServicesReportServerinMyAssembly.dll"
/>
</CodeGroup>
i still get #Error
i try everything , i don't know what i can do.
pls help
View 1 Replies
View Related
Dec 20, 2007
Hello,
The main problem I am currently facing is that I do not have the following directory to place the DLL file: C:Program FilesMicrosoft SQL Server80ToolsReport Designer. It is the "Report Designer" part that is missing. I tried adding it, but that didn't work.
Any ideas why that is?
Thank you.
-Gumbatman
View 4 Replies
View Related
Mar 14, 2007
How do I reference report items (such as textboxes, datasets, tables, etc...) from within a custom assembly?
Thanks!
View 3 Replies
View Related
Sep 27, 2007
I'm having a terrible time trying to figure out how to do this, does anyone have experience?
My code works fine in the report viewer, but all I get from the deployment is #Error symbols. I've added my custom dll file to the config file and gave it full trust, as well as the URL of the web service I'm calling. I've even modified the rest of the codegroups within the file to FullTrust just in case.
I've also added the [assembly: AllowPartiallyTrustedCallers] to the AssemblyInfo class, and [WebPermission(SecurityAction.Assert)] to the constructor of my custom assembly no avail.
I'm at a complete loss now as to why my deployment cannot run this code. As far as debugging goes, Visual Studio is not located on the reporting server, nor is it an option to have it put there. I've been able to run the code with the web service lines commented out, but as soon as I put even the webservice.Credentials = CredentialCache.DefaultCredentials in I'm greeted with the nice and calming #Error.
Any suggestions?
View 1 Replies
View Related
Dec 1, 2006
I have a SqlDataSource that has a parameter that I am trying
to set.
The item is stored in a session field called “GameObject�
Game Object is a simple class that has a several variables.
I am trying to access the .name data member of the class.
<asp:SessionParameter Name="GameCode" SessionField="((GamingSystem)Session[‘GameObject’]).Name" />
This does not work. Is there a way to declarative bind to
the item that I am for.
View 3 Replies
View Related
Aug 10, 2007
We have a custom assembly that worked fine with SSRS 2000. Now that we have upgraded to SQL 2005 we get an "Access is denied" error when attempting to deploy reports that reference this assembly. I could swear that when we first attempted it it worked. We decided to make a minor change to the assembly code and that's when the problem started, even though I've since reverted back to the original code to make certain that the minor change wasn't the issue. The assembly is in the proper folder - C:Program FilesMicrosoft SQL ServerMSSQL.2Reporting ServicesReportServerin - and the reports are referencing the current version. I've searched high and low on the web for an answer but have found nothing even remotely helpful. All this code does is return a string...it's not doing anything that should require any additional security; and even then I doubt if there would be a problem when deploying.
The full text of the error is:
Error while loading code module: €˜Reporting, Version=1.0.2778.12272, Culture=neutral, PublicKeyToken=null€™. Details: Could not load file or assembly 'Reporting, Version=1.0.2778.12272, Culture=neutral, PublicKeyToken=null' or one of its dependencies. Access is denied.
Any ideas? Anyone? I'm at my wit's end on this!
Thanks,
Mike
View 5 Replies
View Related
Mar 7, 2006
Hi all,
my problem is that: I do read informations (e.g. connectionString) from configuration file by one custom assembly.
My environment is RS2005, VS.NET 2005 Prof.Edition, WIN2003 Server SP1, .NET Framework 2.0.50727
The scenario is that:
A text box into my report require a function contained into MyCustom.dll. This code do read information from MyCustom.dll.config.
This file contains:
<?xml version="1.0" encoding="utf-8" ?>
<configuration>
<connectionStrings>
<add name="IS2009cfg" connectionString="data source=servernameinstancename;initial catalog=dbname;user id=xx;password=yy;" />
</connectionStrings>
<appSettings>
<add key="DefaultHeaderLogo" value="This is a test" />
</appSettings>
</configuration>
Using
ConnectionStringSettings conn = ConfigurationManager.ConnectionStrings["IS2009cfg"];
the result is null.
Also using
string defaultHeaderLogo = ConfigurationManager.AppSettings["DefaultHeaderLogo"];
the result is null.
MyCustom.dll and MyCustom.dll.config are located into locations of Report Server and Report Designer, with this Build Events on succesfully build:
rem Copy custom assembly to ReportDesigner location...
copy "...mydeveloplocation...inDebugMyCustom.dll" "C:Program FilesMicrosoft Visual Studio 8Common7IDEPrivateAssembliesMyCustom.dll"
copy "...mydeveloplocation...inDebugMyCustom.dll.config" "C:Program FilesMicrosoft Visual Studio 8Common7IDEPrivateAssembliesMyCustom.dll.config"
rem Copy custom assembly to ReportServer location...
copy "...mydeveloplocation...inDebugMyCustom.dll" "C:Program FilesMicrosoft SQL ServerMSSQL.4Reporting ServicesReportServerinMyCustom.dll"
copy "...mydeveloplocation...inDebugMyCustom.dll.config" "C:Program FilesMicrosoft SQL ServerMSSQL.4Reporting ServicesReportServerinMyCustom.dll.config"
The question is simple: where I do locate configuration file for obtain value during report execution?
Many thank's in advance
Claudio Barca
Turin - Italy
View 2 Replies
View Related
Mar 25, 2008
We use reporting services to report on our SQL 2005.
I wanted to have a function that translates a filter (parameter) in one RDL from IDs to Names to be able to show a summary of what the user selected when he executed the report.
Instead of writing this function in the .Code, I said great, lets use custom assemblies.
PROBLEM: I see examples on how to enable a function in such dll access to DB, but they all hardcode the connection string in the vb code. that seems useless to me. Each customer will have different server name, I need to get the connection string from the sme (shared data source) used in the catalog's folder. just like the RDl is using it. how do I do that?
View 1 Replies
View Related
Apr 7, 2008
I have a custom assembly that uses a config file to obtain database connection settings. This dll is then used by my sql report. I have added refrerenced to all the required dll's in my report and added the required code groups to all the necessary files. I have also placed my app.config file in C:Program FilesMicrosoft SQL ServerMSSQL.3Reporting ServicesReportServer and C:Program FilesMicrosoft Visual Studio 8Common7IDEPrivateAssemblies
However when I actually run the report in the designer (vs2005) I am receiving Null reference exceptions when my code tries to read my config file because it is reading the machine.config file and not my app.config file. If I hard code my connection string everything works fine.
Can anyone tell me why the machine.config file would be referenced instead of my app.config file and how I can stop it from doing this?
View 6 Replies
View Related
Mar 7, 2007
Hi there.
I have an assembly, call it A1, that I've deployed to a SQL Server 2005 database. I can use the managed stored procedures from A1 in SQL Server no problem.
In A1 there is a bit of code which uses the Assembly.Load() method, so load another assembly and use instances of class found in that external assembly. However, when I run the managed stored proc in A1 that uses Assembly.Load() I get the error:
Could not load file or assembly 'A1, Version=1.0.0.0, Culture=neutral,PublicKeyToken='????' or one of its dependencies. The system cannot find the file specified.
(note: for security I've changed some of the above line).
So I changed the Assembly.Load() to use
System.Data,Version=2.0.0.0,Culture=neutral,PublicKeyToken=b77a5c561934e089
I re-built the project, re-deployed it and ran the code in SQL Server - it worked. I could create an instance of a System.Data.DataSet for example. So why can't I load my own custom assembly? My assembly does have a strong name and it's installed in the GAC. I wrote a console app to try and Assembly.Load() my custom assembly and that worked fine (it was also running on the same server as the SQL Server).
So it's defiantely the SQL Server that can't 'see' my customer assembly. What do I need to do this assembly so that SQL Server will allow me to Assembly.Load it, just as it can with System.Data?
Thanks
Jas.
View 1 Replies
View Related