请教版主一个基本概念
<p>在autodesk c#.net的例题三中</p><p><br/>public void createCircle()<br/>{</p><p>Circle circle; </p><p>BlockTableRecord btr;</p><p>BlockTable bt;</p><p>Transaction trans;</p><p>trans = HostApplicationServices.WorkingDatabase.TransactionManager.StartTransaction();</p><p>circle = new Circle(new Point3d(10, 10, 0), Vector3d.ZAxis, 2);<br/>bt = (BlockTable)trans.GetObject(HostApplicationServices.WorkingDatabase.BlockTableId, OpenMode.ForRead);</p><p>btr = (BlockTableRecord)trans.GetObject(HostApplicationServices.WorkingDatabase.CurrentSpaceId,OpenMode.ForWrite );</p><p>btr.AppendEntity(circle);<br/>trans.AddNewlyCreatedDBObject(circle, true); //and make sure the transaction knows about it!</p><p>trans.Commit();</p><p>trans.Dispose();</p><p>}</p><p>把bt = (BlockTable)trans....这句注释掉,程序依然照常执行,那通过这句话来打开模型空间有什么用呢?<br/></p> <p>没什么用,autodesk的示例代码一直都没什么改进,呵呵</p>
页:
[1]