Questions tagged [autocad]

Drafting and design software.

AutoCAD is produced by Autodesk Inc. It is a base product for many of their software offerings that are designed for specific tasks such as architectural, mechanical and civil drafting. AutoCAD is customizable by means of several APIs.

  • Autolisp - A flavor of LISP.
  • VBA - Microsoft VBA became available as an API during the release of AutoCAD 14 prior to 2000. Autodesk has warned that VBA will not be supported in releases after 2012... but it is, even in native 64-bit for the 1st time in v2014.
  • Managed .NET - A managed .NET API is currently the customization platform of choice for many AutoCAD programmers. Of the .NET languages C# is currently the most popular but VB.NET has a stronger-than-usual following because of AutoCAD's VBA history.
  • the JavaScript API was introduced in v2014.
  • ObjectARX/ObjectDBX - A native C++ based API that became available during the release of AutoCAD 13. Less popular than the .NET API because it requires writing much more code and more complex code to accomplish most tasks. Some types of projects (complex custom objects) can only be done via this API.

Autodesk also licenses two stand-alone AutoCAD environments to develop on top of, RealDWG and AutoCAD OEM. OEM has a user interface and RealDWG does not. The licensing model for each is very different - OEM is licensed as a percentage of each sale, RealDWG has fixed license costs.

There is an independent reverse-engineered library that is compatible with AutoCAD made by the Open Design Alliance. Compatibility can lag a little when Autodesk does its 3-yearly binary shuffle and changes the file format. AutoCAD v 2013 changed the application's internal structure, as well as the file format.

The ODA is not open-source nor is it free (as in beer but it is free as in speech) and is not necessarily cheaper than Autodesk's licensing, depending on if / how many sales you make. ODA's Teigha is used as the basis for products like IntelliCAD etc. You can build stand-alone applications on it.

Resources

1395 questions
3
votes
1 answer

draw outline for some connected lines

I have some lines that are connected at various points. I want to draw the outline of these lines and I also want to deal with the extra lines at the connection points. I have seen two similar questions in this website: Here and here I have handled…
Vahid
  • 5,144
  • 13
  • 70
  • 146
3
votes
2 answers

Integrate AutoCad with a WPF C# appllication

I have a question about integrating AutoCad LT with a WPF C# application. I have a client for whom I develop a ERP application, this client uses AutoCAD LT to draw their products which they produce. They use main-drawings for their products,…
Marcel
  • 31
  • 1
  • 3
3
votes
2 answers

Passing arguments to .NET-defined commands

I need to write a command on the command line on Autocad 2000i and I want autocad to prompt for a parameter. Then my vb.net program will act based on the recieved parameter. Basically I guess my solution is all here:…
Tomer S
  • 39
  • 1
  • 5
3
votes
1 answer

Caliburn micro in no Application object mode, like in AutoCAD dll plugin

I am using Caliburn Micro to develop WPF application. A few of views of this application needs to be loaded in an AutoCAD environment. The AutoCAD programming environment allows developement of AutoCAD plugins (of type dll) and load them into the…
Jatin
  • 4,023
  • 10
  • 60
  • 107
3
votes
1 answer

Conversion of 3D WireFrame into 3D Solid Models

I have been working with some 3D Wire Frame Models, which are essentially a large number of vertices which are joined together by edges or line segments to create a 3D Wire Frame of a 3D Object. I was wondering what would it take to convert this 3D…
arun nath
  • 773
  • 1
  • 6
  • 11
3
votes
1 answer

How to transform second polyline according to first polyline

I have 2 polylines: I have drawn the first polyline and extruded a region along this polyline. After this, I need to process the second polyline to start at the correct position (moving the 2nd polyline start point to 1st polyline end point) but I…
3
votes
2 answers

AutoCad EndPlot event firing too soon in (C#, API)

i am leveraging the AutoCad API's to do the following... 1] open autocad 2] load a document 3] print the document 4] close autocad All this is working fine except for the fact that autocad is closing too quickly before the document has finished…
Grant
  • 11,138
  • 32
  • 94
  • 140
3
votes
0 answers

Draw arc with angles ranging from -360 to 360 degrees

I am having some trouble trying to implement drawing an arc. Basically it's supposed to be drawn exactly like how you can draw a 3 point arc in AutoCAD. I can get the arc to draw with start and end angles from from -180 degrees to 360, but if I try…
Just Ask
  • 329
  • 2
  • 6
  • 22
2
votes
1 answer

Geting Text Object Attributes in Autocad with Python

I need to find a selected text object's coordinates in Autocad with python. For this purpose, i use comtypes. But all i found on the net was about getting the line and polyline objects' coordinates. Can you please supply me with the method i can use…
Shansal
  • 1,369
  • 5
  • 16
  • 26
2
votes
1 answer

Win32Com connection failure to Autocad via Python

I need to connect and control AutoCAD via COM interface. For this purpose, I use Python. In my first trial with a very basic snippet(1), I got an error. The code is: import win32com.client acad = win32com.client.Dispatch("AutoCAD.Application") doc =…
Shansal
  • 1,369
  • 5
  • 16
  • 26
2
votes
2 answers

added typelib via makepy for AutoCAD, now win32com not working for AutoCAD

I have been running win32com to access AutoCAD for quite some time without issue. I learned that applying the makepy utility could create a more user friendly experience at the interactive prompt, so I ran it and added the "AutoCAD 2006 Type…
ionalchemist
  • 398
  • 2
  • 17
2
votes
1 answer

Get blocks from Autocad /Maps into excel

I would like to get some objects on a Autocad map layer and extract their name, color and position and place them into an excel sheet in the following manner: Object Name | Color | Coordinates Is there any way to do that programatically? Is there…
Hectoret
  • 3,553
  • 13
  • 49
  • 56
2
votes
3 answers

Writing to dxf or dwg format?

I have the X and Y values for a curve in C# and I want them to be drawn in a dxf or dwg file format using the same C# project. Is there a way to do that? Thank you.
gmk
  • 47
  • 1
  • 6
2
votes
2 answers

3D CAD to OpenGL

I was wondering if anyone knew of a program that can take a 3D drawing of an object and then convert it into the required OpenGL points and normals. Basically I have an AutoCAD drawing of that I want to be able to display in a program I am creating…
MZimmerman6
  • 8,445
  • 10
  • 40
  • 70
2
votes
2 answers

Is thera an Autocad export file so it is programmatically readable?

I would like to extract the coordinates (latitude, longitude) and some properties like name and colour of Autocad files. I may do this from a Java program. From Autocad, which is the right format to export to so I can programmatically parse the…
Hectoret
  • 3,553
  • 13
  • 49
  • 56