dotnet interop:
Hello.
Don't know if this is the right group, but my problem involves COM interop,
hence the post to this group.
We have a simple API which we use to send messages to a private MSMQ queue.
This API is C#, and it abstracts some of the details in using the
System.Messaging namespace. It runs without problems on ASP.NET using 2003
server.
Now, I wish to use this API in asp pages on a 200 server machine.
I have created a C# class library which exposes a "SendMessage" method to
COM. This method uses my .NET messaging API.
Registering of dlls and Server.CreateObject works fine, but I get a strange
FileNotFoundException when System.Messaging.MessageQueue.Send(Object obj)
eventually gets invoked.
The error message says "File or assembly name 2agydadi.dll or one of its
dependencies, was not found."
The strange thing about this exception is that the name of the file that is
not found changes each time I reload the asp page.
Does anyone have an idea what this means?
Here is the stack trace:
Exception: System.IO.FileNotFoundException - File or assembly name
2agydadi.dll, or one of its dependencies, was not found. /
at System.Reflection.Assembly.nLoad(AssemblyName fileName, String
codeBase, Boolean isStringized, Evidence assemblySecurity, Boolean
throwOnFileNotFound, Assembly locationHint, StackCrawlMark& stackMark)
at System.Reflection.Assembly.InternalLoad(AssemblyName assemblyRef,
Boolean stringized, Evidence assemblySecurity, StackCrawlMark& stackMark)
at System.Reflection.Assembly.Load(AssemblyName assemblyRef, Evidence
assemblySecurity)
at System.CodeDom.Compiler.CompilerResults.get_CompiledAssembly()
at System.CodeDom.Compiler.CompilerResults.get_CompiledAssembly()
at System.Xml.Serialization.Compiler.Compile()
at System.Xml.Serialization.TempAssembly..ctor(XmlMapping[] xmlMappings)
at System.Xml.Serialization.XmlSerializer..ctor(Type type, String
defaultNamespace)
at System.Xml.Serialization.XmlSerializer..ctor(Type type)
at System.Messaging.XmlMessageFormatter.Write(Message message, Object
obj)
at System.Messaging.Message.AdjustToSend()
at System.Messaging.MessageQueue.SendInternal(Object obj,
MessageQueueTransaction internalTransaction, MessageQueueTransactionType
transactionType)
at System.Messaging.MessageQueue.Send(Object obj)
at
Test.Messaging.Queueing.Providers.MicrosoftMessageQueueProvider.Send(String
message)
at Test.Messaging.MessageBase.Send()
at TestInterop.MSMQStarter.SendMessage(Int32 refNo, String emailOverride)
Thanks in advance
Christer