Polymorphic bit flags in C++

I often encounter cases in ObjectARX programming where numerous boolean flags need to be persisted as part of an AutoCAD database object. For filing and for passing around to other functions, it’s most efficient to package those bit flags into a single unsigned integer. Below is an example that demonstrates how to use a union inside a containing class that can be simultaneously used as either a single unsigned integer or as individual booleans. ...

December 19, 2012 · 2 min · Owen Wengerd

Checking function return values

A lot of you are guilty of not checking return values from API function calls. I’ll bet you have a good excuse, like “it’s a lot of extra typing for no reason”, or “that function should never return an error code”. ...

August 30, 2012 · 2 min · Owen Wengerd

Turning off InfoCenter (aka WSCommCntr4.exe) in AutoCAD 2013

I have updated the AcadInfoCenterOff.msi file on the ManuSoft Freebies page for AutoCAD 2013. If you’re not sure what it does or why you need it, see this previous post on the subject.

March 28, 2012 · 1 min · Owen Wengerd

Registering an ARX/BRX module as a COM server

If you’re developing ARX modules that need to be registered as a COM server, you’re faced with some decisions about how to register them. In the old days before anyone cared about user permissions, registration could be safely accomplished at runtime, even via AutoLISP. Unfortunately runtime COM server registration just doesn’t work reliably any more under limited user accounts, not to mention registry redirection on 64-bit platforms. There is only one reliable way to register COM servers, and that’s doing it at install time under elevated privileges. ...

October 11, 2011 · 3 min · Owen Wengerd

OpenDCL 6

You may not have noticed, but AutoLISP is still alive and kicking. This is evidenced by the growing community of developers and hobbyist programmers using the latest release of OpenDCL, the free graphical user interface library for AutoLISP applications. If you’re not familiar with OpenDCL, check out the newly released OpenDCL 6.

August 5, 2011 · 1 min · owenwengerd

A tale of two tethers

Those of you using your Android phone as an internet connection may be paying more than you need to pay. Many phone companies here in the US charge extra to enable tethering capability, either by providing their own OEM tethering app or by enabling the phone to serve as a Wi-fi hotspot. ...

June 3, 2011 · 2 min · Owen Wengerd

The MFC Balloon

The MFC version that ships with Visual Studio 2010 is known to cause major explosions in file size when you link statically. To avoid that problem, I use the Visual Studio 2008 build tools for such cases. I recently got quite a surprise when I rebuilt one such MFC application and discovered that the executable had ballooned from 400kb to 2MB in the space of one week despite only very minor changes. ...

April 15, 2011 · 2 min · Owen Wengerd

BRX on Linux: Getting Started

When I heard that Bricsys had shipped Bricscad for Linux, I was anxious to get to work on supporting the Linux platform. The first order of business was getting familiar with Linux. For that, I chose Ubuntu 10.10 32-bit running on a VMWare Workstation 7.1 virtual machine hosted on my Windows 7 64-bit workstation. ...

April 10, 2011 · 3 min · Owen Wengerd

ObjectARX Wizard for Visual Studio 2010

If you’re an ObjectARX programmer, you may still be using Visual Studio 2008 because you’ve been told that you must. It’s true that you need Visual Studio 2008 installed to compile native ObjectARX code, but with Daffodil you can do all your work in the Visual Studio 2010 IDE. ...

April 1, 2011 · 1 min · Owen Wengerd

AutoCAD 2012 InfoCenter

If you’re upgrading to AutoCAD 2012, don’t forget to also disable InfoCenter (unless you really need it). Just download and install AcadInfoCenterOff to disable it on any version of AutoCAD or AutoCAD LT. If you already have AcadInfoCenterOff installed, you can just run a repair install to apply it to a newly installed instance of AutoCAD 2012.

March 25, 2011 · 1 min · Owen Wengerd

Simplifying the problem: plain vanilla configuration

One of the stages in simplifying an AutoCAD software problem is to rule out (or in) third party add-ons as the cause. To do that, you’ll need a “plain vanilla” test bed configuration that consists of only the out-of-the-box components with no add-ons loaded. ...

February 26, 2011 · 2 min · Owen Wengerd

Simplifying the problem: divide and conquer

When a customer reports a drawing-specific issue, the next stage in simplifying the problem is to eliminate all drawing content that has no bearing on the problem. Unless the drawing object that causes the problem is obvious and can be immediately ascertained, I use the divide-and-conquer method to zero in on the cause. ...

February 25, 2011 · 3 min · Owen Wengerd