Version property

Dear Acad gurus, I try to connect to AutoCAD from other application programmatically (on run-time) The issue is that I try to obtain the client AutoCAD version. I make an instance of the AutoCAD as an OLE, and obtain the version property. I tried it on various AutoCAD versions in order to know what will I get. The results are: AutoCAD 2004 -> 16.0s (LMS Tech) AutoCAD 2002 -> 15.06s (LMS Tech) AutoCAD 2000 -> ?????? AutoCAD 14 ->14.0 Does it mean that if first two digits are 16 it will always be AutoCAD 2004? What version should I expect from AutoCAD 2000 & AutoCAD 2000i? Thanks,

Reply to
A D
Loading thread data ...

HiHO; The first six bytes of a DWG file identify its version. AC1018: AutoCAD 2004 AC1015: AutoCAD 2002, 2000i, 2000 AC1014: AutoCAD Release 14 (Release 14 sample drawings use AC1013) AC1012: AutoCAD Release 13 AC1009: AutoCAD Releases 12, 11 AC1006: AutoCAD Release 10 AC1004: AutoCAD Release 9 AC1002: AutoCAD Release 2.6 AC1.50: AutoCAD Release 2.05

Reply to
bestafor

To the best of my knowledge, using this: (atoi (substr (getvar "acadver") 1 2))

R2004 will return 16 R2002, R2000i, R2000 will return 15 R14 will return 14

Reply to
R.K. McSwain

Reply to
R.K. McSwain

Thanks for all repliers, very helpful. I think i didn't explained myself very well. I try to take the version outside AutoCad, by instanceing AutoCad as OLE object and use the version property. So, the results are diffrent from what I get from DWG file (it could be great idea, but it don't fit me) As well, (atoi (substr (getvar "acadver") 1 2)) Is problematic for me since i'm , actually , outside from AutoCad, so I got the folowing results with the version property: AutoCAD 2004 -> 16.0s (LMS Tech) AutoCAD 2002 -> 15.06s (LMS Tech) AutoCAD 14 ->14.0 The problem that I can't install AutoCad 2000 or 2000i since i'm use XP. Does anyone know what value the version property will return on AutoCad 2000 & 2000i? Thanks again,

Reply to
A D

AutoCAD 2000 and 2000i can be installed in XP, check out compatibility mode.

Reply to
Al

Ok, so in whatever language you are using, take the returned value and = strip it down to an integer. Then compare to:

16 =3D R2004 15 =3D R2002, R2000i, R2000=20 14 =3D R14

If you need to tell the difference between 2000 and 2000i and 2002 - do = a google search, it's out there. There are different values depending on = level of service pack, etc.

All versions of AutoCAD from R13 up will run on XP - as verified by me = :) R12 might even work also.

"A D" wrote...

Reply to
R.K. McSwain

Thank you very much, That's exactly what I've been looking for! Thanks, thanks, thanks! BTW, officially, XP support only AutoCAD 2004 & 2002 I'll goggle for the difference between 2000, 2000i & 2002 Have a great day!

Reply to
A D

Did you really expect Autodesk to tell you that you can use older versions? They want to sell you a new one.

Reply to
CW

I guess their a lot of truth in what u writing, but for me, with my application that communicate with AutoCAD, under XP, It does not work with

14, but it work with 2002 & 2004, So, I'm blocking the user for use in such configuration (14 & XP). Maybe the reson is another one. But it give me a fair solution to my problem. Thanks,
Reply to
A D

I never said anything about "supported" on XP, I only said R13 and up = would "run" on XP.

Reply to
R.K. McSwain

PolyTech Forum website is not affiliated with any of the manufacturers or service providers discussed here. All logos and trade names are the property of their respective owners.