frostrap Posted September 23, 2008 Posted September 23, 2008 I haven't ventured into the world of xdata yet, but there are some projects that I'd like to try out at work that could make use of xdata. It looks like xdata might be somewhat limmitted regarding the amount of information you store in it. For instance, I beleive I can store one entity handle with an object as a piece of xdata. What is I wanted to store two entity handles? I can store one 3D point, but what if I wanted to store an entire list of 3D points? Is there something out there that is tightly integrated with autocad like xdata is, but that also has more flexability regarding the information that is attached to a specific object? Or am I throwing the xdata baby out with the bathwater? Thanks, Joe Quote
rocheey Posted September 23, 2008 Posted September 23, 2008 >>Is there something out there that is tightly integrated with autocad like xdata is, but that also has more flexability regarding the information that is attached to a specific object? Try XRecords. They are a lot more robust, and abit more secure - at least in the sense that some user playing with express tools cant hose your information. Quote
frostrap Posted September 23, 2008 Author Posted September 23, 2008 Ah, I remember hearing about those now. I'll start researching in that direction. Thanks! Quote
ASMI Posted September 23, 2008 Posted September 23, 2008 If you look for lisp solution find VLAX-LDATA-... functions. For example attach dictionary "My Dict" to any entity and write dotted pairs list of string, integer and 3D coordinate list: Command: (vl-load-com) Command: (setq ent(car(entsel))) Select object: <Entity name: 7efa3368> Command: (vlax-ldata-put ent "My Dict" '((0 . "My string")(1 . 233)(3 . (2.44 17.0 22.04)))) ((0 . "My string") (1 . 233) (3 2.44 17.0 22.04)) Read dictionary content: Command: (vlax-ldata-get ent "My Dict") ((0 . "My string") (1 . 233) (3 2.44 17.0 22.04)) It's fast and easy... Quote
Recommended Posts
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.