I'm trying to use a statically linked C library. I've wrapped a .NET C++ DLL
around this lib and trying to drive the wrapper from a .NET VB testbed. The
whole build succeeds but I get the following error message at runtime:
An unhandled exception of type 'System.TypeLoadException' occurred in
TiffLibXTester.exe
Additional information: Could not load type tiff from assembly TiffLibX,
Version=1.0.1425.19884, Culture=neutral, PublicKeyToken=null.
I would appreciate any help on this and in general, on what the best way is
to use legacy libraries (either lib or dll) from .NET.
Thanks,
Ladvánszky Károly 5 1510
it's probably forward declared as
struct tiff;
What you need to do in MC++ is:
struct tiff{};
"Ladvánszky Károly" <lk@digicart.hu> wrote in message
news:%2***************@TK2MSFTNGP09.phx.gbl... I'm trying to use a statically linked C library. I've wrapped a .NET C++
DLL around this lib and trying to drive the wrapper from a .NET VB testbed.
The whole build succeeds but I get the following error message at runtime:
An unhandled exception of type 'System.TypeLoadException' occurred in TiffLibXTester.exe
Additional information: Could not load type tiff from assembly TiffLibX, Version=1.0.1425.19884, Culture=neutral, PublicKeyToken=null.
I would appreciate any help on this and in general, on what the best way
is to use legacy libraries (either lib or dll) from .NET.
Thanks,
Ladvánszky Károly
Thanks for your answer.
Where should I place it in MC++? Everything compiles and links with no
problem.
Károly
"Pent" <pent> az alábbiakat írta a következő hírüzenetben:
#5*************@TK2MSFTNGP11.phx.gbl... it's probably forward declared as struct tiff; What you need to do in MC++ is: struct tiff{};
"Ladvánszky Károly" <lk@digicart.hu> wrote in message news:%2***************@TK2MSFTNGP09.phx.gbl... I'm trying to use a statically linked C library. I've wrapped a .NET C++ DLL around this lib and trying to drive the wrapper from a .NET VB testbed. The whole build succeeds but I get the following error message at runtime:
An unhandled exception of type 'System.TypeLoadException' occurred in TiffLibXTester.exe
Additional information: Could not load type tiff from assembly TiffLibX, Version=1.0.1425.19884, Culture=neutral, PublicKeyToken=null.
I would appreciate any help on this and in general, on what the best way is to use legacy libraries (either lib or dll) from .NET.
Thanks,
Ladvánszky Károly
anywhere
"Ladvánszky Károly" <lk@digicart.hu> wrote in message
news:eG**************@TK2MSFTNGP12.phx.gbl... Thanks for your answer. Where should I place it in MC++? Everything compiles and links with no problem.
Károly
"Pent" <pent> az alábbiakat írta a következő hírüzenetben: #5*************@TK2MSFTNGP11.phx.gbl... it's probably forward declared as struct tiff; What you need to do in MC++ is: struct tiff{};
"Ladvánszky Károly" <lk@digicart.hu> wrote in message news:%2***************@TK2MSFTNGP09.phx.gbl... I'm trying to use a statically linked C library. I've wrapped a .NET
C++ DLL around this lib and trying to drive the wrapper from a .NET VB
testbed. The whole build succeeds but I get the following error message at runtime:
An unhandled exception of type 'System.TypeLoadException' occurred in TiffLibXTester.exe
Additional information: Could not load type tiff from assembly
TiffLibX, Version=1.0.1425.19884, Culture=neutral, PublicKeyToken=null.
I would appreciate any help on this and in general, on what the best
way is to use legacy libraries (either lib or dll) from .NET.
Thanks,
Ladvánszky Károly
To my surprise, it has worked. I have the source files of the library in
question and struct tiff is declared.
What does this empty struct declaration do?
Could you please explain the solution a little more detailed?
Is it MC++ specific?
Thanks,
Károly
"Pent" <pent> az alábbiakat írta a következő hírüzenetben:
e6**************@TK2MSFTNGP11.phx.gbl... anywhere
"Ladvánszky Károly" <lk@digicart.hu> wrote in message news:eG**************@TK2MSFTNGP12.phx.gbl... Thanks for your answer. Where should I place it in MC++? Everything compiles and links with no problem.
Károly
"Pent" <pent> az alábbiakat írta a következő hírüzenetben: #5*************@TK2MSFTNGP11.phx.gbl... it's probably forward declared as struct tiff; What you need to do in MC++ is: struct tiff{};
"Ladvánszky Károly" <lk@digicart.hu> wrote in message news:%2***************@TK2MSFTNGP09.phx.gbl... > I'm trying to use a statically linked C library. I've wrapped a .NET C++ DLL > around this lib and trying to drive the wrapper from a .NET VB testbed. The > whole build succeeds but I get the following error message at
runtime: > > An unhandled exception of type 'System.TypeLoadException' occurred
in > TiffLibXTester.exe > > Additional information: Could not load type tiff from assembly TiffLibX, > Version=1.0.1425.19884, Culture=neutral, PublicKeyToken=null. > > I would appreciate any help on this and in general, on what the best way is > to use legacy libraries (either lib or dll) from .NET. > > Thanks, > > Ladvánszky Károly > >
Forward declarations prevent MC++ compiler from generating "metadata" for
these types. http://www.winterdom.com/mcppfaq/archives/000262.html http://groups.google.com/groups?selm...ngxa06.phx.gbl
search: groups.google.com
for: TypeLoadException group:microsoft.public.dotnet.languages.vc.*
"Ladvánszky Károly" <lk@digicart.hu> wrote in message
news:ei**************@TK2MSFTNGP10.phx.gbl... To my surprise, it has worked. I have the source files of the library in question and struct tiff is declared. What does this empty struct declaration do? Could you please explain the solution a little more detailed? Is it MC++ specific?
Thanks,
Károly
"Pent" <pent> az alábbiakat írta a következő hírüzenetben: e6**************@TK2MSFTNGP11.phx.gbl... anywhere
"Ladvánszky Károly" <lk@digicart.hu> wrote in message news:eG**************@TK2MSFTNGP12.phx.gbl... Thanks for your answer. Where should I place it in MC++? Everything compiles and links with no problem.
Károly
"Pent" <pent> az alábbiakat írta a következő hírüzenetben: #5*************@TK2MSFTNGP11.phx.gbl... > it's probably forward declared as > struct tiff; > What you need to do in MC++ is: > struct tiff{}; > > "Ladvánszky Károly" <lk@digicart.hu> wrote in message > news:%2***************@TK2MSFTNGP09.phx.gbl... > > I'm trying to use a statically linked C library. I've wrapped a
..NET C++ > DLL > > around this lib and trying to drive the wrapper from a .NET VB testbed. > The > > whole build succeeds but I get the following error message at runtime: > > > > An unhandled exception of type 'System.TypeLoadException' occurred in > > TiffLibXTester.exe > > > > Additional information: Could not load type tiff from assembly TiffLibX, > > Version=1.0.1425.19884, Culture=neutral, PublicKeyToken=null. > > > > I would appreciate any help on this and in general, on what the
best way > is > > to use legacy libraries (either lib or dll) from .NET. > > > > Thanks, > > > > Ladvánszky Károly > > > > > >
This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: Tim Mulholland |
last post by:
Hello all,
Our company is trying to write some code in C#/.NET that we don't want an
end user to be able to see. The algorithms are not that complex, but are
sensitive such that if a user could...
|
by: Dan |
last post by:
Hi Gurus
I got a very basic question to ask:
When a .NET exe (MSIL) is first run, the JIT-compiler will converts the IL
into native codes so that it can executes on the current machine. my...
|
by: Michael |
last post by:
The other day I was looking around in the GAC and I noticed
some strange things. For startings, I don't see any Microsoft
libraries that have a version number 1.1. I only see 1.0.5000
and...
|
by: Kenneth McDonald |
last post by:
For unfortunate reasons, I'm considering switching back to Win XP
(from OS X) as my "main" system. Windows has so many annoyances that
I can only compare it to driving in the Bay Area at rush hour...
|
by: Tcs |
last post by:
My backend is DB2 on our AS/400. While I do HAVE DB2 PE for my PC, I haven't
loaded it yet. I'm still using MS Access. And no, I don't believe this is an
Access question. (But who knows? I...
| |
by: Gustavo L. Fabro |
last post by:
Greetings!
Some classes that once compiled without problems on VS 2003 have now
problems on VS 2005 Beta 1. I'm talking about a __nogc class that is
exported with __declspec(dllexport).
The...
|
by: Kevin Walzer |
last post by:
....with a twist.
I'm undertaking my first semi-substantial Python GUI application after a
long time dabbling with the language.
I'm fairly experienced with Tcl/Tk, so Tkinter seems the...
|
by: hammad.awan_nospam |
last post by:
Hello,
I'm wondering if it's possible to do the following with Generics:
Let's say I have a generic member variable as part of a generic class
like this:
List<DLinqQuery<TDataContext>>...
|
by: ChopStickr |
last post by:
I have a custom control that is embedded (using the object tag) in an html document.
The control takes a path to a local client ini file.
Reads the file.
Executes the program specified in...
|
by: ablock |
last post by:
I have an array to which i have a added a method called contains. I
would like to transverse this array using for...in...I understand
fully that for...in is really meant for Objects and not Arrays,...
|
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...
| |
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...
|
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,...
|
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: 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...
|
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...
|
by: TSSRALBI |
last post by:
Hello
I'm a network technician in training and I need your help.
I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs.
The...
| |
by: 6302768590 |
last post by:
Hai team
i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
|
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
| |