Jump to content

Add extended data for 3d solid


DuanJinHui

Recommended Posts

Hello friends

 

Inventor and solidworks draw 3D parts , can give this parts naming.

But Sometimes I use AutoCad draw 3D solid ,Can't give this 3d solids naming.

 

I hope use "XDATA" , add extended data for these 3d solids. Have such a routine ?

 

Extended data only some string ,

For example,

Name: Air cylinder

type: Festo DNC-32-25-PPV-A

Description: Suppliers etc.

Link to comment
Share on other sites

To mimic the way that inventor works in AutoCAD.

 

Either

 

Add the meta data as DWGprops and then x-ref your part models into an assembly DWG file...

 

Or

 

Turn each part model into a block and use attributes to hold the meta data.

 

You can then use Dataextraction to create a BOM table.

 

Does that help?

 

Paul

Link to comment
Share on other sites

To mimic the way that inventor works in AutoCAD.

 

Either

 

Add the meta data as DWGprops and then x-ref your part models into an assembly DWG file...

 

Or

 

Turn each part model into a block and use attributes to hold the meta data.

 

You can then use Dataextraction to create a BOM table.

 

Does that help?

 

Paul

 

Paul . you mean :make attribute blocks with 3D solid ?

Link to comment
Share on other sites

I found some information .

LeeMac at theswamp. Thanks Lee.

(defun cd:xdt_getxdata ( ent app )
   (cdr (assoc -3 (entget ent (list (cond (app) ("*"))))))
)
(defun cd:xdt_putxdata ( ent app lst )
   (regapp app)
   (entmod (reverse (cons (list -3 (cons app lst)) (reverse (entget ent)))))
)
(defun cd:xdt_removexdata ( ent app / lst )
   (if (setq lst (cdr (assoc -3 (entget ent (list (cond (app) ("*")))))))
       (entmod (list (cons -1 ent) (cons -3 (mapcar 'list (mapcar 'car lst)))))
   )
)

 

(cd:xdt_putxdata (car (entsel))"Remark" '((1001 . "Remark") (1000 . "Air cylinder")(1000 . "DNC-32-25-PPV-A")(1000 . "Festo")))

 

(cd:xdt_getxdata (car (entsel)) "Remark")

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...