473,386 Members | 1,726 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,386 software developers and data experts.

Help Needed...its urgent plz

Hi someone plz help me. I have made a dll in VC++ .NET using following
specifications

extern "C"
{
__declspec(dllexport) void Probe_Interfaces_Local()
{
//some code
}

}

i compiled it successfully and add the dll formed to another C# project
directory. The c# code looks like this...

using System;
using System.Runtime.InteropServices;

namespace read
{
class Capture
{
[DllImport("mod2.dll")]
public static extern void Probe_Interfaces_Local();
//some code
}
}

The C# project compiles successfully but when i run it it breaks with
dll exception and says unable to load dll(mod2.dll)

Please help somebody......u can also mail at kn***********@yahoo.co.in

Dec 29 '05 #1
3 1002

<sh***************@gmail.com> ???????/???????? ? ???????? ?????????:
news:11**********************@z14g2000cwz.googlegr oups.com...
Hi someone plz help me. I have made a dll in VC++ .NET using following
specifications

extern "C"
{
__declspec(dllexport) void Probe_Interfaces_Local()
{
//some code
}

}

i compiled it successfully and add the dll formed to another C# project
directory. The c# code looks like this...

using System;
using System.Runtime.InteropServices;

namespace read
{
class Capture
{
[DllImport("mod2.dll")]
public static extern void Probe_Interfaces_Local();
//some code
}
}

The C# project compiles successfully but when i run it it breaks with
dll exception and says unable to load dll(mod2.dll)

Please help somebody......u can also mail at kn***********@yahoo.co.in


Put "mod2.dll" near the C# assembly.
Dec 29 '05 #2
<sh***************@gmail.com> wrote

The C# project compiles successfully but when i run it it breaks with
dll exception and says unable to load dll(mod2.dll)

If you compiled mod2.dll with /MD (shared CRT) you need
a manifest. See the /manifestdependency and /manifest switches
and the MT tool.

With the mixed mode debugger you can also enable LDR
notifications (e.g. with gflags or via the _ShowSnaps
symbol in ntdll.dll). The debugger output will contain
additional information for the LoadLibrary call.

-hg
Dec 29 '05 #3
that probably means that your application cannot find the dll at runtime.
it should be in the same folder as your application, or its containing
folder should be listed in the path variable.

kind regards,
Bruno.
<sh***************@gmail.com> wrote in message
news:11**********************@z14g2000cwz.googlegr oups.com...
Hi someone plz help me. I have made a dll in VC++ .NET using following
specifications

extern "C"
{
__declspec(dllexport) void Probe_Interfaces_Local()
{
//some code
}

}

i compiled it successfully and add the dll formed to another C# project
directory. The c# code looks like this...

using System;
using System.Runtime.InteropServices;

namespace read
{
class Capture
{
[DllImport("mod2.dll")]
public static extern void Probe_Interfaces_Local();
//some code
}
}

The C# project compiles successfully but when i run it it breaks with
dll exception and says unable to load dll(mod2.dll)

Please help somebody......u can also mail at kn***********@yahoo.co.in

Dec 30 '05 #4

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

Similar topics

2
by: choksi | last post by:
Hello All I am running PHP5.0.2 over apache 1.3.29 and openssl-0.9.7d on a Debian Linux and with a fake (internal)ip. Php Configure command './configure' '--with-apxs=/www/bin/apxs'...
12
by: Vibhajha | last post by:
Hi friends, My sister is in great problem , she has this exam of C++ and she is stuck up with some questions, if friends like this group provides some help to her, she will be very grateful....
2
by: trihanhcie | last post by:
I m currently working on a Unix server with a fedora 3 as an os My current version of mysql is 3.23.58. I'd like to upgrade the version to 5.0.18. After downloading from MYSQL.COM the package on...
7
by: meenasamy | last post by:
Hi all, i need to create a function that takes three parameters( Original currency, needed currency, amount) i need to convert from the original currency to the needed currency the amount and...
1
by: dasilva109 | last post by:
Hi guys I am new to C++ and need urgent help with this part of my code for a uni coursework I have to submit by Thursday //ClientData.h #ifndef CLIENTDATA_H #define CLIENTDATA_H #include...
2
by: Preetam Pattanashetty | last post by:
Hi I am learning ASP.NET using C#. I am able to run .aspx files on local system, but when I load them to the server, I get the "Server Error in '/' Application" error. I have tried to configure the...
1
by: Domini | last post by:
Hi all, I need urgent help with an xml issue. Let me explain the scenario: My VB.NET app needs to read an xml (e.g. Sales Orders). This xml contains say 10 sales orders. Next the app needs to split...
1
by: irfi | last post by:
Ok can anyone help me with this problem I have to create a program in NetBeans 4.0 and this is the requirement:- I have to create a base class which consists of EMPLOYEE NAME, CODE and...
0
by: Christopher | last post by:
Urgent Help Needed: The EPVH-1.1 Visual Hull Library. Dear All, I am a student doing research in computer vision. The EPVH-1.1 Visual Hull Library will really help a lot in my research. I...
1
by: toskg | last post by:
I am seeking an Urgent Help from all my seniors and experts to complete my assignment. I am doing a Project for Multi-Level Marketing(MLM) Co. Website using ASP (DreamWeaver 8.0) and MS-Access as...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
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
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.