473,395 Members | 1,379 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,395 software developers and data experts.

problem using mixed code dlls with asp.net

I have a c# application that calls a mixed code dll which in turn calls an
unmanaged dll that has an inline template class constructor.

The c# application runs fine until I use it on IIS

The problem only occurs the first time you run it in a debugger.
When it tries to enter into the unmanaged C++ inline template class it fails
saying that it can't find the specific code ... if you look at the
disassembly you will see that this template class does a jmp to an invalid
address.

If you stop the debugger and restart it you will not see the problem.
Anyone got any ideas ????
Nov 17 '05 #1
1 1120
It turns out that this behaviour was down to strong naming and its set up ....
When the managed dll had the following conditions
1) built as strong named
2) included in the GAC
3) copy local.Net IDE set as true
4) All the .Net caches cleaned out

The Result was :
1st Run : No Problem
Close the debugger
Open the debugger
Run : Thec# application calls into the managed code fine but when the
managed code calls the unmanaged code it bombs out.

The above happens also if the strong named dll isn't included in the gac and
copy local.Net IDE set as true

The only time it does work is if the strong named dll is included in the gac
and copy local.Net IDE set as false

I can't find anything on the web to support this , Does anyone have an
explaination for this behavior ... pretty please ;-)

"HMANG" wrote:
I have a c# application that calls a mixed code dll which in turn calls an
unmanaged dll that has an inline template class constructor.

The c# application runs fine until I use it on IIS

The problem only occurs the first time you run it in a debugger.
When it tries to enter into the unmanaged C++ inline template class it fails
saying that it can't find the specific code ... if you look at the
disassembly you will see that this template class does a jmp to an invalid
address.

If you stop the debugger and restart it you will not see the problem.
Anyone got any ideas ????

Nov 17 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
by: Mike Woinoski | last post by:
(I'm new to VS, so please forgive me if this is a faq.) I'm writing some Java web services and need to test them with C++ clients. I can use either a Windows Form application or an MFC application....
1
by: rudi | last post by:
Hi everybody, I have a problem with a mixed mode application. It consists of an unmanaged C++ dll, a "mixed mode" dll and various VB.NET dlls using the mixed mode dll to talk to the unmanaged...
4
by: quortex | last post by:
Hey all, I have been working on a project which consists of Native C++ code and managed C# code. In order for the managed C# code to be able to access the native layer I wrap some objects using...
3
by: Mali Guven | last post by:
Hello, I have a native DLL (written in C) which is supposed to call a managed DLL (was written in C#, and an entry point was injected modifying the ildasm'd code). The exectuable calls the...
6
by: John | last post by:
I have 5 native static libraries that are being compiled in Visual Studio 2005 with the /MDd C Runtime option. I have 2 CLR DLLs (all managed code) in Visual Studio 2005 and the /MDd C Runtime...
6
by: S Wheeler | last post by:
I have a REALLY nasty problem and could use some expert help. I have two mixed mode apps. Each uses a mixed mode DLL that exports a couple of classes. There is no dll main as it is not needed....
0
by: MC-Advantica | last post by:
I have built a managed wrapper class and assembly that expose much functionality available in unmanaged legacy DLLs. I can write VB apps that interface with the managed assembly, and the managed...
1
by: =?Utf-8?B?RmFiaWFu?= | last post by:
Hello, I want to give multiple native classes (in different mixed mode dlls) access to a managed output window (for error messages). Therefore I wrote a native singleton with __declspec...
5
by: =?Utf-8?B?aWduaGVucnk=?= | last post by:
I have a managed C++ project and two C# projects. All are class library projects. The C++ project links with native C++ static libraries and references to one C# project. The projects structure...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.