' Add reference to AutoCAD/ObjectDBX Common 16.0 Type Library (axdb16enu.dll) ' This samples copies all dimstyles from specified drawing to the current drawing ' Existing dimstyles are not affected Public Sub ImportDimstyles() Dim oAxDbDoc As New AxDbDocument oAxDbDoc.Open "c:\DimStyles.dwg" Dim oObj() As Object Dim oDs As AcadDimStyle Dim i As Integer For i = 0 To oAxDbDoc.DimStyles.Count - 1 ReDim Preserve oObj(i) Set oObj(i) = oAxDbDoc.DimStyles(i) Next oAxDbDoc.CopyObjects oObj, ThisDrawing.Database.DimStyles End Sub
Tuesday, January 17, 2006
Copy dimstyles between drawings using VBA
| JTB World |
^ Top of page
Translate into Français | Deutsch | Italiano | Português | Español | 日本 | 한국의 | 中國
Translate into Français | Deutsch | Italiano | Português | Español | 日本 | 한국의 | 中國
Subscribe to:
Post Comments (Atom)
Some of the latest blog posts
Contact Us
| About JTB World |
Subscribe to this blog
JTB World's website |
Website General Terms of Use |
Privacy Policy
^ Top of page
© 2004- JTB World. All rights reserved.
Restored comments
ReplyDeleteAnonymous said...
Could not get this to work in ADT 2006.
Some type of error in the Public Sub statement.
May 30, 2006
JTB World said...
Did you add reference to AutoCAD/ObjectDBX Common 16.0 Type Library?
May 30, 2006