Skip to content

Instantly share code, notes, and snippets.

@lm913
Last active December 16, 2015 16:17
Show Gist options
  • Save lm913/a747d35677adfe8f5cc3 to your computer and use it in GitHub Desktop.
Save lm913/a747d35677adfe8f5cc3 to your computer and use it in GitHub Desktop.
Script to count path points
var docRef = app.activeDocument;
try{
var numPaths = docRef.pathItems.length;
var countPoints = docRef.pathItems[0].subPathItems[0].pathPoints.length;
if (numPaths > 0){
alert(countPoints);
}
}
catch (numPaths) {
alert("No paths exist!");
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment