473,320 Members | 2,145 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,320 software developers and data experts.

Error: Invalid PInvoke metadata format

Hi,

An unhandled exception of type 'System.TypeLoadException' occured in
system.dll

Additional information: Invalid PInvoke metadata format

Im getting this error afrer calling myConnection.Open();
Im connecting to Firebird database (im trying in fact)
I don't know whats wrong :( Please Help.

This is piece of code:

string connectionString =
"User=SYSDBA;" +
"Password=masterkey;" +
"Database=test2.fdb;" +
"DataSource=localhost;" +
"Port=3050;" +
"Dialect=3;" +
"Charset=NONE;" +
"Role=;" +
"Connection lifetime=15;" +
"Pooling=true;" +
"Packet Size=8192";
FbConnection myConnection = new FbConnection(connectionString);

myConnection.Open();

Thanx

gacu

Nov 16 '05 #1
2 2489
Gacu,

This sounds like a bug with the connection class. Is there more
information in the call stack that you can display that would possibly show
the error?
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"Gacu" <ga**@poczta.onet.pl> wrote in message
news:jm******************@news.chello.at...
Hi,

An unhandled exception of type 'System.TypeLoadException' occured in
system.dll

Additional information: Invalid PInvoke metadata format

Im getting this error afrer calling myConnection.Open();
Im connecting to Firebird database (im trying in fact)
I don't know whats wrong :( Please Help.

This is piece of code:

string connectionString =
"User=SYSDBA;" +
"Password=masterkey;" +
"Database=test2.fdb;" +
"DataSource=localhost;" +
"Port=3050;" +
"Dialect=3;" +
"Charset=NONE;" +
"Role=;" +
"Connection lifetime=15;" +
"Pooling=true;" +
"Packet Size=8192";
FbConnection myConnection = new FbConnection(connectionString);

myConnection.Open();

Thanx

gacu

Nov 16 '05 #2
Hi Nicholas,

You are right. I've reinstalled .net data provider for Firebird. I had
provider for
..net framework 1.1 version
now I have provider for
..net framework 1.0 version

It works now! :) That's strange because I got 1.1 .net framework installed
for sure. Maybe something is wrong with my system.

Thanx.
gacu
Gacu,

This sounds like a bug with the connection class. Is there more
information in the call stack that you can display that would possibly show the error?

Nov 16 '05 #3

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

Similar topics

4
by: muser | last post by:
Can anyone run this program through their compiler or if they can see a logical error please point it out. I have my tutor working on it at the moment but I would rather a less ambigious response...
0
by: Craig Watt | last post by:
Please Help! I have an XML File using the DataPacket standard (am working with Delphi/Informix poeple): <?xml version="1.0" standalone="yes"?> <DATAPACKET version="2"> <METADATA> <FIELDS>...
0
by: Claire | last post by:
Hi Ive been using Mattias Sjögren's example at http://www.msjogren.net/dotnet/eng/samples/dotnet_dynpinvoke.asp to load an unmanaged 3rd party dll dynamically when my object is created. Calling...
11
by: Steve Hoyer | last post by:
I am trying to deploy my first asp.net app to our webserver (2K server, IIS 5) My start page comes up and you can get to the subsequent pages that are tied into our sql server (2K). Each page...
0
by: Don Lopez | last post by:
I get this exception when I try to run open on the MySQLConnection object. It goes like this: System.TypeLoadException: Invalid PInvoke metadata format. at...
1
by: Miku | last post by:
Hi Guies, I am new to vb.net. In my project I am using vb.net & MySql 4.0.17 as a backend. For database connectivity i have downloaded ByteFX - Mysql .net native provider. I have written the...
0
by: HKSHK | last post by:
This list compares the error codes used in VB.NET 2003 with those used in VB6. Error Codes: ============ 3: This Error number is obsolete and no longer used. (Formerly: Return without GoSub)...
1
by: keerthikarani | last post by:
hi, I m using the following code in vb.net, but it shows me some error, can u explain why this error occurs and how to rectify it, but the following code works fine in vb Private Declare...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
0
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 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 former...

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.