#target Illustrator
var doc = app.activeDocument;
var cp = doc.views[0].centerPoint;
var zm = doc.views[0].zoom;
var objOutside = new Array();
var t = .001;
doc.views[0].zoom = 5.9;
for (var a=0; a < doc.artboards.length; a++) {
doc.artboards.setActiveArtboardIndex(a);
var abBounds = doc.artboards[a].artboardRect;
var abt = [];
abt[0] = [(abBounds[0]-1-t), abBounds[1]+t, abBounds[0]-t, abBounds[3]-t];
abt[1] = [abBounds[2]+t, abBounds[1]+t, abBounds[2]+1+t, abBounds[3]-t];
abt[2] = [abBounds[0]-t, abBounds[1]+1+t, abBounds[2]+t, abBounds[1]+t];
abt[3] = [abBounds[0]-t, abBounds[3]-t, abBounds[2]+t, abBounds[3]-1-t];
for (var i=0; i < abt.length; i++) {
doc.artboards[a].artboardRect = abt[i];
doc.selectObjectsOnActiveArtboard();
tsel = doc.selection;
for (var s=0; s <tsel.length; s++) {
objOutside.push(tsel[s]);
};
};
doc.artboards[a].artboardRect = abBounds;
};
doc.views[0].centerPoint = cp;
doc.views[0].zoom = zm;
doc.selection = null;
for (var i=0; i < objOutside.length; i++) {
objOutside[i].selected = true;
};