• Industries
  • Products
  • Buy
  • Services & Support
  • Communities
  • Discussion Groups

    .NET

    Reply
    Active Member
    Posts: 8
    Registered: ‎12-20-2012
    Accepted Solution

    what happen to the file of AcMgd.dll in my project

    280 Views, 9 Replies
    12-20-2012 09:58 PM

     Hi ,

     

    Is there somebody can help me?

     

    Everytime, I build my project, there is following warning coming out and asks me to remove the reference file "ACMgd".

     

    Warning 1

     The referenced assembly "AcMgd" could not be resolved because it has a dependency on "System.Web, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" which is not in the currently targeted framework ".NETFramework,Version=v4.0,Profile=Client". Please remove references to assemblies not in the targeted framework or consider retargeting your project. AutoCADHoodDWG

     

    Best regards,

     

    Jusitn

    Please use plain text.
    Contributor
    Posts: 20
    Registered: ‎09-29-2006

    Re: what happen to the file of AcMgd.dll in my project

    12-20-2012 10:38 PM in reply to: jiallxy

    Hi,

     

    - Do you use the correct release of ObjectArx?

    - In VS, did you switch its "Local Copy" property to FALSE?

     

    Regards,

    Please use plain text.
    Valued Contributor
    Posts: 50
    Registered: ‎12-03-2003

    Re: what happen to the file of AcMgd.dll in my project

    12-21-2012 04:32 AM in reply to: jiallxy

    I suppose that you are working with Autocad 2013, if I'm correct, review yor project properties, the target .NET Framework for your app mus be 4.0 (probably you have 3.5).

    Luis Alberto Manero, Geograma.com
    Please use plain text.
    Active Member
    Posts: 8
    Registered: ‎12-20-2012

    Re: what happen to the file of AcMgd.dll in my project

    12-21-2012 05:57 AM in reply to: glanard

    Hi

     

    I use autocad2012 64bit version with win7 64bit os. The C:\ObjectARX 2012 is my folder for ObjectARX.

     

    I use VS 2010 C# to program a stand alone application.

     

    all of them are reommended by autodesk's website. They shuould work together properly.

    Please use plain text.
    Mentor
    Posts: 241
    Registered: ‎05-12-2009

    Re: what happen to the file of AcMgd.dll in my project

    12-21-2012 06:29 AM in reply to: jiallxy

    jiallxy wrote:

     Hi ,

     

    Is there somebody can help me?

     

    Everytime, I build my project, there is following warning coming out and asks me to remove the reference file "ACMgd".

     

    Warning 1

     The referenced assembly "AcMgd" could not be resolved because it has a dependency on "System.Web, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" which is not in the currently targeted framework ".NETFramework,Version=v4.0,Profile=Client". Please remove references to assemblies not in the targeted framework or consider retargeting your project. AutoCADHoodDWG

     

    Best regards,

     

    Jusitn



    Try retargeting to full .NET 4.0 version instead of Client.
    You can also find your answers @ TheSwamp
    Please use plain text.
    *Expert Elite*
    Posts: 681
    Registered: ‎04-27-2009

    Re: what happen to the file of AcMgd.dll in my project

    12-21-2012 07:48 AM in reply to: jiallxy

    Now than you mentioned this:

     

    <quote>

    I use VS 2010 C# to program a stand alone application.

    </quote>

     

    Please be aware, the Acad .NET API assemblies (acdbmgd.dll/acmgd.dll...) can only be used inside AutoCAD (if you do Acad addin DLL project). You CANNOT use them with stand-alone EXE project.

    Please use plain text.
    Moderator
    Alexander.Rivilis
    Posts: 1,168
    Registered: ‎04-09-2008

    Re: what happen to the file of AcMgd.dll in my project

    12-21-2012 07:54 AM in reply to: jiallxy

    jiallxy wrote:

    Hi

     

    I use autocad2012 64bit version with win7 64bit os. The C:\ObjectARX 2012 is my folder for ObjectARX.

     

    I use VS 2010 C# to program a stand alone application.

     

    all of them are reommended by autodesk's website. They shuould work together properly.


    Do I understand correctly that you're trying to make external exe-file (not dll-file that will be loaded with NETLOAD command into AutoCAD)? If so, then you can not use acmgd.dll and acdbmgd.dll in your project.


    Пожалуйста не забывайте про Утвердить в качестве решения!Утвердить в качестве решения и Give Kudos!Баллы
    Please remember to Accept Solution!Accept as Solution and Give Kudos!Kudos

    Please use plain text.
    Active Member
    Posts: 8
    Registered: ‎12-20-2012

    Re: what happen to the file of AcMgd.dll in my project

    12-21-2012 11:54 AM in reply to: Alexander.Rivilis

    Yes, you are right.

     

    I have just found that these two dll files only can be used in add-in projects.

     

    I have to use COM interop: Autodesk.AutoCAD.Interop

     

    The problem is that the COM interop have less good functions and is more difficult to program.

     

    I will try to balance which way I should choose.

     

    thank you very much!

     

    Please use plain text.
    Active Member
    Posts: 8
    Registered: ‎12-20-2012

    Re: what happen to the file of AcMgd.dll in my project

    12-21-2012 11:56 AM in reply to: norman.yuan

    Yes, you are right.

     

    I have just found that these two dll files only can be used in add-in projects.

     

    I have to use COM interop: Autodesk.AutoCAD.Interop for standalone application.

     

    The problem is that the COM interop have less good functions and is more difficult to program.

     

    I will try to balance which way I should choose.

     

    thank you very much!

    Please use plain text.
    Active Member
    Posts: 8
    Registered: ‎12-20-2012

    Re: what happen to the file of AcMgd.dll in my project

    12-21-2012 11:57 AM in reply to: jeff

    Thank you!

     

    I changed the framework type, and it works!

    Please use plain text.