Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- forEach(ThisDrawing.PickFirstSelectionSet, function(ent) {
- if (ent.EntityName != "AcDbPolyline") return;
- var vv = new VBArray(ThisDrawing.Utility.CreateSafeArrayFromVector(ent.Coordinates));
- var coords = vv.toArray();
- //echo(coords.length);
- for (i = 0; i<coords.length; i += 2)
- {
- ThisDrawing.Utility.Prompt(coords[i] + "," + coords[i+1]);
- }
- })
- function echo(msg) {ThisDrawing.Utility.Prompt(msg);}
- function forEach(coll, fn) {for (var enu = new Enumerator(coll); !enu.atEnd(); enu.moveNext()) fn(enu.item());}
Advertisement
Add Comment
Please, Sign In to add comment