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

VS2005 msmq BadImageFormatException

Hi all,

I am trying to port an application developed with VS2003 to VS2005. The
project builds successfuly but when I run it, it throws a
BadImageFormatException in the following line of code in the
constructor of my main form :

....
if
(!System.Messaging.MessageQueue.Exists(@".\Private $\CentralInQueue"))
....

The exception window title is:
BadImageFormatException was unhandled.

The exception message is:
An attempt was made to load a program with an incorrect format.
(Exception from HRESULT: 0x8007000B)

The version of the application that was compiled using VS2003 still
runs on the same computer.

I am using VS2005 - Version 8.0.50727.42 and .NET version 2.0.50727.

Any help would be greatly appreciated.

Thanks,
Notis.

May 3 '06 #1
1 1504
OK, after some experimenting I found out that the problem is caused due
to a comon reference of System.Messaging. More specifically:

I have a solution with several projects. One of them is lets say my
application project. Another is a library project with several user
controls in it. Both projects reference System.Messaging.

My library project is referenced by the application project.

When I try to run the application project I get the previously
described exception. If I stop referencing the library project (or I
take out the reference to System.Messaging from the library project)
then the application project runs.
Of course this is only possible for experimentation as I need to
reference the library project in real life.

It seems that VS2005 doesn't like System.Messaging to be referenced
both by the library and by the application project. This used to be no
problem with VS2003.

Any ideas why this is happening and how to get around it?

Thanks,
Notis.

May 4 '06 #2

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

Similar topics

0
by: Andrew Gordon | last post by:
I'm investigating getting Microsoft Navision to do stuff from a Python script. The recommended way seems to be to use message queues (MSMQ). I can get Navision to send a message to itself fine. I...
0
by: Erich Hofacker | last post by:
Hello, I have written an application in .NET (C#) which uses some stuff from the Microsoft.mshtml. Unfortunately some customers reported that they are missing this DLL. Therefore we now...
5
by: Alex Nitulescu | last post by:
Hi. I'm trying to make MSMQ work, so I go to Control Panel, Windows Components, I select MSMQ (Message Queuing Client Setup, actually) and about half-way through I get a nice message box saying ...
9
by: MrSpock | last post by:
1. Create a new Windows Application project. 2. Open the project properties and check "Make single instance application". 3. Build. 4. Go to the release folder and run the application. 5. Try to...
4
by: Roger Aikin | last post by:
I've converted a VB6 project to VB.Net 2005. (Actually using vstudio pro 2005). I'm on a machine that also has VB6 and Vstudio.net 2003 on it. The project uses Word, Excel, MapPoint and SqlClient...
3
by: notis.stamos | last post by:
Hi all, I am trying to port an application developed with VS2003 to VS2005. The project builds successfuly but when I run it, it throws a BadImageFormatException in the following line of code in...
13
by: Dave Booker | last post by:
I need to compile a VS2005 project to run using the 1.1 framework (i.e., app.config containing <supportedRuntime version="v1.1.4322" /> ). (If I just compile and run with such a setting it...
5
by: DBC User | last post by:
Hello, Is there an alternative approach to MSMQ for delivering messages? I am planning to develop an app which I don't want clients to install MSMQ (or do anything otherthan install my app). I...
1
by: Florence Tissot | last post by:
We are seeing some kind of resource leak in our performance lab running an ASP.NET (2.0) application that sends and receives messages from 2 public MSMQ queues. Here's a brief summary of what are...
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
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
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...
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
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...
0
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...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

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.