To Convert VBA Subassemblies to .NET

You can convert AutoCAD Civil 3D stock subassemblies that are VBA-based to .NET. In AutoCAD Civil 3D 2007, and in earlier versions of AutoCAD Civil 3D, the subassemblies that were included in the product were created using VBA.

In AutoCAD Civil 3D 2008, all of the subassemblies included in the product were created using .NET. This is because .NET versions of subassemblies provide faster performance than VBA-based subassemblies when generating corridor models. AutoCAD Civil 3D 2008, and later versions, still support VBA-based subassemblies. For example, in drawings, catalogs, and tool palettes, you can have a mix of VBA-based and .NET-based subassemblies. However, it is recommended that you convert VBA-based subassemblies to .NET using the following procedure to achieve optimal performance when generating corridor models.

To convert subassemblies from VBA to .NET

  1. Click Modify tabDesign panelConvert VBA Subassemblies To .NET Find.
  2. Do one of the following:
    • To convert all subassemblies in the drawing, at the command line, enter A, and then press Enter. All VBA subassemblies in the drawing are converted to VB.NET.
    • To convert all subassemblies in a selected assembly, select an assembly, and then press Enter. All VBA subassemblies in the selected assembly are converted to VB.NET.
  3. Note: This command only converts the VBA-based AutoCAD Civil 3D stock subassemblies that were included with the product. It does not convert any VBA-based subassemblies that were created from user-defined (custom) VBA code.

To display the subassembly definition in the Subassembly Properties dialog box

To determine if a subassembly is VBA-based, .NET-based, or created from a polyline, use the Subassembly Properties dialog box or the Properties palette to display the subassembly definition.

  1. Right-click a subassembly in the drawing and click Subassembly Properties.
  2. In the Subassembly Properties dialog box, click the Parameters tab.

    The Defined From field displays .NET if the subassembly was created using .NET, VBA if it was created using VBA, and Entities if the subassembly was created from a polyline.

To display the subassembly definition in the Properties palette

  1. Right-click a subassembly in the drawing and click Properties.
  2. On the Properties palette, click the Design tab.

    The Geometry Generate Mode property displays .NET if the subassembly was created using .NET, VBA if it was created using VBA, and Entities if the subassembly was created from a polyline.