|
高级会员
注册日期: 06-11
帖子: 14579
精华: 1
现金: 224494 标准币
资产: 234494 标准币
|
【转帖】如何删除已知的空图层
如何删除已知的空图层
如何删除已知的空图层
void
我只知道如何创建一个图层如下
createnewlayer()
{
acdblayertable *playertable;
acdbhostapplicationservices()->workingdatabase()
->getsymboltable(playertable, acdb::kforwrite);
acdblayertablerecord *playertablerecord =
new acdblayertablerecord;
playertablerecord->setname("asdk_mylayer");
// defaults are used for other properties of
// the layer if they are not otherwise specified.
//
playertable->add(playertablerecord);
playertable->close();
playertablerecord->close();
}
但是删除已知的空图层呢
路漫漫其修远兮......
假设获得图层的指针player
player->earse();
acdbobjectidarray ida;
ida.setphysicallength(0)
ida.append(player->id());
acdbcurdwg()->purge(ida);
在player->earse();之后还要加上一句:player->close();
扩展数据编辑器免费下载地址://www.rmb100.cn/downcenter.htm#soft_jxdedt
|