问题描述:

I am currently trying to test a C# client with the NMS Api .dlls in order to communicate with the Message Broker from Apache ActiveMQ. I am developing with Visual Studio C# 2010 Express and my target framework is 4.0 Client Profile. But when I try to build the project I am facing some conflicts which I don’t know how to solve.

My settings are following:

  • .Net Target Framework 4.0 Client Profile
  • Apache.nms-1.5.0.dll
  • Apache.nms.ActiveMQ-1.5.2.dll

When I am trying to build my client I get following conflict (translated from German):

Assembly “Apache.NMS.ActiveMQ” couldn’t be solved because it has a dependency to System.Web, Version=4.0.0.0 which doesn’t exists in the target framework.

Same for Apache.NMS.

How could I solve this issue? As far as i know in .Net 4.0 there isn't a System.Web (Version=4.0.0.0) dll! But the two apache nms dlls are for .Net 4.0.

网友答案:

I think this guy has the same problem as you do.

You're targeting the Client Profile, which doesn't include the Web assemblies. Go into Project > Properties > Application and change Target Framework to ".NET Framework 4".

相关阅读:
Top