473,796 Members | 2,538 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

again a "can't find PInvoke DLL" problem

Hello!

I'm trying to develop a GIS mapping software on smart devices (Pocket
PC) using VS
2005, C#. I need to use a library that was written in C++. Being open
source I compiled the C++ code VS 2005 --C++ --Smart Devices and I
obtained a DLL. Now I need to access the DLL functions (unmanaged
code) from my C# (managed code) application. Unfortunatelly I got a
"Can't find PInvoke dll" problem.

Afterwards I tried to do a simple C++ Smart Device DLL:

extern "C" __declspec(dlle xport) int __stdcall fntest_C()
{
return 42;
}

and just use it in C# to see if it works:

[DllImport("test _C_2.dll",Entry Point="fntest_C ")]
public static extern int fntest_C();

But again I got the same error.... I really don't understand!

I tied also dumpbin.exe /EXPORTS:
:
Section contains the following exports for test_C_2.dll

00000000 characteristics
45FA72B6 time date stamp Fri Mar 16 12:34:30 2007
0.00 version
1 ordinal base
1 number of functions
1 number of names

ordinal hint RVA name

1 0 00001000 fntest_C = fntest_C

Please help... I really don't know what to do... Should I try to
compile the C++ code using eVC instead of VS2005 ? I mention that I
have copied the C++ dll in the same directory as the C# exe file...

Thank you for your patience...

Kind regards,
Raluca

Mar 16 '07 #1
0 1411

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

Similar topics

5
9112
by: Giles Brown | last post by:
I'm feeling quite dumb this morning. I'm trying to build a COM server DLL using py2exe and it ain't working. Here's what ain't working... setup_dll.py based on py2exe sample: """from distutils.core import setup import py2exe
4
3436
by: Askari | last post by:
Yesterday, ALL code in python work and nothing when I close(finish) a code. Today, when I close, some raise this windows error : Instruction at "0x00FC3D70" use memory address "0x00000000". Can't be "read". Click on "OK" to exit program. Why this error, today and not before today?
0
1291
by: Lewap | last post by:
And exception is ArgumentNullException so I think application don't see "module.dll" file. How to resolve this problem? I must declare this dll, or add to project, or place dll under particular directory or set suitable path somwhere in project properties? I develop this dll as separate project.
3
8425
by: Michael Rodriguez | last post by:
I've installed WSE, both 1.0 and 2.0. The namespace Microsoft.Web.Services is visible from my VB.NET projects, but not in C#. In C#, it tells me there is no "Web" under "Microsoft". Any ideas? -- To understand recursion, we must first understand recursion.
3
4144
by: Dmitry Jouravlev | last post by:
Hi, I have a number of C++ solutions in Visual Studio .NET and when i compile them using "Whole Program Optimization", certain projects report a LNK1171 error saying that c2.dll could not be loaded. The error contains the correct path to c2.dll (and it is definately there). This only happens on some projects and only when "whole program optimization" option is turned on. If i turn off this option, the problem goes away. I have other...
22
3306
by: EP | last post by:
When running my asp.net hosting service (asp.net without IIS), on server 2003 with IIS not installed, I get the following when trying to process a request. "System.DllNotFoundException: Unable to load DLL (aspnet_isapi.dll)." Of course the dll is able to be found, it's still in the framework directory and for grins I even put it in my service's local directory. This is apparantly server 2003 not allowing asp.net to be run if IIS was not...
5
3906
by: touf | last post by:
Hi, I'm having this error when I try to open a report (Crystal reports) on the client machine (It works fine on my developpement machine) It's a window application (not a web), On the client machine the framwork was installed using a VB.net CD's that doesn't contain Crystal, but The application is installed by an installer generated from my machine using vs.net 2002. I've found somewhere on google that this is an error related to web...
0
1099
by: Thomas W | last post by:
Hello, I'm trying to call a function from a C++ dll which is declared as VARIANT DLLEXPORT ExecuteFunction (LPCSTR); This function (which I can't change) executes a SQL query and returns a single value - whatever the query asks for: integer, string, double etc.
3
4358
by: angshuman.agarwal | last post by:
Structure in C DLL ---------------------------- typedef struct IrData { unsigned short uiFormat; unsigned short uiLength; unsigned char* pchData; } tagIrData; Function in C DLL
0
9684
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, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9530
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 effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10236
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 tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
10182
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
9055
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7552
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6793
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5577
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
3
2928
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

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.