[求助]在arx中如何读出lisp写的扩展数据
在arx中如何读出lisp写的扩展数据有一以前的系统是LISP写的
在以前的系统中生成有如下的扩展数据,我现在的代码是ARX写的,要兼容以前的数据,就用读取这样扩展数据,在Arx中能不能读出这些数据,如何读出。或者有没有其他方法,只要能读出这些数据,让我在Arx代码中用就可以。
我一直用arx开发,lisp基本不懂
(-3 ("控规:街坊" (1002 . "{") (1000 . "APA-01") (1000 . "居住")
(1000 . "2000") (1000 . "0.00") (1000 . "25.6") (1000 . "4.1") (1000 .
"12班小学1所,6班幼儿园2所,垃圾中转站1处") (1000 . "无") (1000 .
"20060418-0.001") (1002 . "}")))
高手指教!
搞规划的吧,你lisp不懂就会arx,比俺强多了,用AutoCAD MAP,直接转到RDB里,还编什么程啊
我是用C语言写的程序.
struct resbuf *rb2,*rb1;
rb1=ads_buildlist(RTSTR,"APA-01",0);
rb2=ads_entgetx(ent,rb1);
assoc_dxf_str(rb1,1000,sTemp);
... ...
上边assoc-dxf_str函是检索数据链表的.详细如下
------ 缓冲链表操作函数 5.链表检索(字符型) -------------- */
int assoc_dxf_str(struct resbuf *rb,int dxf_code,char *result)
{
struct resbuf *rb1;
if (dxf_type(dxf_code)!=RTSTR) return RTERROR;
if (rb==NULL) return RTERROR;
for (rb1=rb;rb1!=NULL;rb1=rb1->rbnext)
{ if (rb1->restype==dxf_code)
{
strcpy(result,rb1->resval.rstring);
return RTNORM;
}
}
return RTERROR;
}
/***************************************************************************/
------ 缓冲链表操作函数 1.节点类型*/
int dxf_type(int dxf_code)
{
if (dxf_code>=1000) dxf_code=dxf_code-1000;
if (dxf_code=0 && dxf_code=10 && dxf_code=38 && dxf_code=60 && dxf_code=210 && dxf_code
页:
[1]