Arx returns the DXF method of object traversal.
A. The traversal of DXF mainly relies on these two functions:
Get ads_name: acdbgetadsname (ads, objid)
Obtain the DXF linked list: acdbentget (ADS)
B. In addition, the structure of the return DXF linked list
Restype: DXF Code. For more information, see the help documentation of DXF. Commonly Used 100-Class 8-Layers
Resval: the value of the DXF code. The value belongs to the Union type. For details, see the type in the help document of DXF. For example, the value is a string when DXF = 100, and the value is a double type when DXF = 40.
Refer to the following code: traverse the DXF
Ads_name ads;
If (acdbgetadsname (ads, objid) = ACAD: Eok)
{
Resbuf * presbuf = acdbentget (ADS );
If (presbuf! = NULL)
{
Resbuf * pnext = presbuf;
For (; pnext! = NULL; pnext = pnext-> rbnext)
{
// DXF code value
If (pnext-> restype = 40)
{
// Query the DXF data to find the corresponding value type
Ftextheight = pnext-> resval. Rreal;
Break;
}
}
}
}
Owed by: spring night rain http://blog.csdn.net/chunyexiyu reprint please indicate the source
Note-ARX object traversal DXF Method