Can the QCAD Application Framework be accessed through a Windows application like Excel VBA?

Proposal: We would like to measure a product and dynamically send values to the QCAD Application Framework to create a DXF drawing with the objects and position required.For example: Draw an arc and place small objects along the arc at specific distances or angles.Include text at various positions of the objects.

If this application is a good fit for QCAD which product is required to access this functionality?Is there an example Excel VBA application that demonstrates this functionality?

I have no experience with Windows specific products or technologies such as Excel or VBA but I can answer the QCAD side of the question.

To launch QCAD from another process and hand over some data, one would typically use a file (DXF, CSV, XML or any other convenient file format to transfer the data in question) or an SQL database.

To dynamically interact with QCAD from another process while QCAD is already running there are several IPC (inter process communication) mechanisms that can be employed:

Use command line arguments to trigger an event

Generally, only one QCAD process can be running at a time. Launching QCAD again if it is already running will not start QCAD again but instead pass the command line arguments to the running instance of QCAD. This can be used for a simple way of IPC. For example if QCAD is already running and you launch it again, with these arguments:

This will create a new drawing in the already running instance of QCAD. Instead of running this existing script to create a new drawing, any other (custom) script can be run whenever needed to do virtually anything (import a file, add an entity, perform an auto zoom, etc).

Network (TCP/IP)

Since QCAD scripts have access to the Qt API, a network server / client protocol could be used to communicate with QCAD.

Polling

A QCAD script could be used to regularly check if a file on disk has changed, a new file has been created in a specific directory for processing or importing, etc.

Plugins

A QCAD C++ plugin could be used to make any (platform specific) technology available to interact with QCAD.

Excerpt________With the QCAD Application Framework it is not only possible to create interactive tools but also to construct entire drawings based on user input (dialog, command line arguments, ...), mathematical formulas, data bases, files or other sources.

This tutorial focuses on creating objects with the QCAD Application Framework and adding them to a drawing document. The example in this tutorial creates a drawing document from scratch, adds various objects to it and saves the document as a DXF file. No user interface is used for this example, so it can be run as a command line application without first starting the QCAD Application user interface.

End of excerpt____________

Microsoft Excel has a development environment called VBA.Visual Basic for Applications.

VBA programs can be used for control of other application through various mechanisms.The code example on the ribbonsoft website looks like VBA.

I am the main developer of QCAD. Almost all of QCAD has been developed directly by me, including the script interface.

Please understand that QCAD is a cross-platform software that works on Windows, Mac OS X and Unix systems. This means that it is using cross-platform technologies whenever possible. There is in fact very little code in QCAD that is platform dependent.

Unfortunately, I have never heard of the "Windows automation class reference" (= "Windows automation API"?). The best lead I can provide is that QCAD is developed using the Qt framework (http://www.qt-project.org). It is possible that either Qt or the Windows API provide some standard interfaces to communicate with a Qt / Windows application through the Windows automation API. However, that would not be something that has been tested or I would have any experience with.

TeighaC++ development environment that includes full support for .dwg/.dxf and DGN files, a powerful object-oriented C++ API, and a rich feature set for editing, manipulating and rendering CAD data. Also supports Teigha Xtensions for building custom objects and custom commands.

Teigha.NETA set of SWIG-generated .NET wrappers that encapsulate the Teigha C++ API. Teigha.NET API class and function names are identical to the underlying C++ names, making the transition to .NET easy for Teigha C++ developers.