.NET
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Acdbmgd versions compatibility issues

3 REPLIES 3
Reply
Message 1 of 4
junoj
426 Views, 3 Replies

Acdbmgd versions compatibility issues

In one my codes I am using a property of an Editor [ ActiveViewportId ] and I am able to compile that when I reference the (acdbmgd, acmgd) from 2011 without any problems.

 

When I try to do the same for the 2008, I get an error stating that [ ‘ActiveViewportId’ is not a member of ‘Autodesk.AutoCAD.EditorInput.Editor’ ]

 

Do we as .net programmers have a remedy for situations like the one above? Can we import objects from one class library to another? I am just trying to find the best way on how someone would go about trying to make their code compatible across several versions of AutoCAD.

Thank you,

 

-J

3 REPLIES 3
Message 2 of 4
dgorsman
in reply to: junoj

Thats a pretty big jump between versions.  Later versions frequently include things which are not available in older versions, and there is nothing to be done about it aside from coding based on the most restrictive environment (forward compatibility is always easier).  Otherwise, you need to code specifically for the quirks and limitations of each version.

----------------------------------
If you are going to fly by the seat of your pants, expect friction burns.
"I don't know" is the beginning of knowledge, not the end.


Message 3 of 4
junoj
in reply to: junoj

So with .NET one has to “compile their code” overtime a new version of CAD is issued. Because it appears that it’s not only backward incompatible but it’s also forward incompatible too.

 

I tried running my 2008 code in 2013 and it does not work.

 

I ask this because files like lisp and vba have been running on multi versions of CAD without any issues, and with .NET it’s less than 5 and the code needs amendments.

 

So how would one go about keeping track with their .NET code? Procedures, best practices; I would like to learn and adapt good habits. Any advice on this topic would be appreciated.

Message 4 of 4
_gile
in reply to: junoj

Hi,

 

There're very few forward compatibility issues with the .NET API, except the 2013 "big split".

 

I have many programs targeting the A2007 SDK (Framework 2.0) which work from A2007 to A2012 without any changes in the code nor need to new compilation, and which only needed a new compilation referencing A2013 assemblies to work with A2013-2014.

 

By my side, the only forward compatibility problem I encountered before 2013 was with abstract method Drawable.ViewportDraw() which changed to Drawable.SubViewportDraw() with A2010 (see here).



Gilles Chanteau
Programmation AutoCAD LISP/.NET
GileCAD
GitHub

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Autodesk DevCon in Munich May 28-29th


Autodesk Design & Make Report

”Boost