DotNetNewsgroup.com  
web access to complete list of Microsoft.NET newsgroups
   home   |   control panel login   |   archive  |  
 
  carried group
academic
adonet
aspnet
aspnet.announcements
aspnet.buildingcontrols
aspnet.caching
aspnet.datagridcontrol
aspnet.mobile
aspnet.security
aspnet.webcontrols
aspnet.webservices
assignment_manager
datatools
dotnet.distributed_apps
dotnet.general
dotnet.myservices
dotnet.nternationalization
dotnet.scripting
dotnet.security
dotnet.vjsharp
dotnet.vsa
dotnet.xml
dotnetfaqs
framework
framework.clr
framework.compactframework
framework.component_services
framework.controls
framework.databinding
framework.drawing
framework.enhancements
framework.interop
framework.odbcnet
framework.performance
framework.remoting
framework.sdk
framework.setup
framework.webservices
framework.windowsforms
framework.wmi
frwk.windowsforms.designtime
lang.csharp
lang.jscript
lang.vb
lang.vb.controls
lang.vb.data
lang.vb.upgrade
lang.vc
lang.vc.libraries
  
 
start date: Wed, 08 Aug 2007 07:35:08 -0700,    posted on: microsoft.public.dotnet.framework        back       

Thread Index
  1    unknown


using a COM library in a SQL CLR procedure   
I've installed a COM object on my machine and a development server
(that is running SQL 2005).  On my machine, a wrote a quick command
line app to test usage of the COM object and it works.  I copied the
application to the server and it works there too.  When I write a new
class library application using the COM object the same way, but in a
method that will be a SQL CLR procedure it fails.  The assembly and
stored procedure are successfully created, but when I execute the
procedure, I get the error below.  The assembly is created with
PERMISSION_SET = UNSAFE.  Also, the .NET build process is creating 3
outputs, an Interop.COMObjectName.dll file, the project file (.exe
or .dll) and a .pdb file.

Any ideas about what is causing the problem, how to solve it, or where
to start looking for the solution?
Thanks.

Msg 10314, Level 16, State 11, Line 2
An error occurred in the Microsoft .NET Framework while trying to
load
assembly id 65681. The server may be running out of resources, or the
assembly may not be trusted with PERMISSION_SET = EXTERNAL_ACCESS or
UNSAFE. Run the query again, or check documentation to see how to
solve the assembly trust issues. For more information about this
error:

System.IO.FileLoadException: Could not load file or assembly
'nameparsemelissadata, Version=0.0.0.0, Culture=neutral,
PublicKeyToken=null' or one of its dependencies. The given assembly
name or codebase was invalid. (Exception from HRESULT: 0x80131047)
System.IO.FileLoadException:
   at System.Reflection.Assembly.nLoad(AssemblyName fileName, String
codeBase, Evidence assemblySecurity, Assembly locationHint,
StackCrawlMark& stackMark, Boolean throwOnFileNotFound, Boolean
forIntrospection)
   at System.Reflection.Assembly.InternalLoad(AssemblyName
assemblyRef, Evidence assemblySecurity, StackCrawlMark& stackMark,
Boolean forIntrospection)
   at System.Reflection.Assembly.InternalLoad(String assemblyString,
Evidence assemblySecurity, StackCrawlMark& stackMark, Boolean
forIntrospection)
   at System.Reflection.Assembly.Load(String assemblyString)
Date:Wed, 08 Aug 2007 07:35:08 -0700   Author:  

Google
 
Web dotnetnewsgroup.com


COPYRIGHT ?2005, EUROFRONT WORLDWIDE LTD., ALL RIGHT RESERVE  |   Contact us