Create Block Error
Dim blck as AcadBlockDim inspoint1 as VariantDim utilObj as AcadUtilitySet utilObj = ThisDrawing.UtilityutilObj.CreateTypedArray inspoint1, vbDouble, 0, 0, 0Set blk = ThisDrawing.Blocks.Add(inspoint,"Any")why a type mismatch error at last statement
Comments
-
Will this help?Dim blck As AcadBlock Dim InsPnt(0 To 2) As Double InsPnt(0) = 0 '= X coordinateInsPnt(1) = 0 '= Y coordinateInsPnt(2) = 0 '= Z coordinate Set blck = ThisDrawing.Blocks.Add(InsPnt, "Any")Arno van Eeuwen
0 -
No unfortunately not - same errorDoes it have something to do with the references in my project Amongst OthersBricsCAD DB 2.3 Type LibraryAutoCAD 2006 Type LibraryBricsCAD App 1.0 Type LibraryI have AutoCAD 2002,2006,2007 & 2008 installed
0 -
Try changing to this:Dim blck As BricscadDb.AcadBlockWith various Cad objects on one system, I also have had similar problems.By specifying specificly a 'BricsCad' Block, you avoid declaring an 'Autocad' block and then linking in to a BricsCad block.Hope this helps,Arno
0 -
Heres the rub! My BricsCAD DB Library doesn't expose an AcadBlock Object yet it does AcadBlocks. There is also an IAcadBlock although this seems to be DBX related
0