Dynamic Curve Length Selection?
All  1  2-4

Previous
Next
 From:  Michael Gibson
7927.2 In reply to 7927.1 
Hi OSTexo, I don't remember any already existing script for that, but here is a new one that should do that:

script: /* Select by curve length */ var min = 1.0, max = 5.0; var crvs = moi.geometryDatabase.getObjects().getCurves(); for ( var i = 0; i < crvs.length; ++i ) { var crv = crvs.item(i); var len = crv.getLength(); if ( len>= min && len <= max ) { crv.selected = true; } }


Edit the "min" and "max" values near the start of the script to change the range.

- Michael
  Reply Reply More Options
Post Options
Reply as PM Reply as PM
Print Print
Mark as unread Mark as unread
Relationship Relationship
IP Logged

Previous
Next
 From:  Frenchy Pilou (PILOU)
7927.3 In reply to 7927.2 
Does the script can work also for simple lines?

In fact yes! :)

Just something : Select nothing before call the script!

If you want an only one exact length input same value for Min and Max !:)

French Version
http://moiscript.weebly.com/select-by-length.html

EDITED: 21 Apr 2016 by PILOU

  Reply Reply More Options
Post Options
Reply as PM Reply as PM
Print Print
Mark as unread Mark as unread
Relationship Relationship
IP Logged

Previous
 From:  OSTexo
7927.4 
Hello,

Thank you Michael, this will save me hours of cleanup work.
  Reply Reply More Options
Post Options
Reply as PM Reply as PM
Print Print
Mark as unread Mark as unread
Relationship Relationship
IP Logged
 

Reply to All Reply to All

 

 
 
Show messages: All  1  2-4