Delete all image collections
I am looking for a way to delete all image collections from the Collections tab. Is this possible with a custom javascript for Br?
I am looking for a way to delete all image collections from the Collections tab. Is this possible with a custom javascript for Br?
Thank you!
I know how put the script in the BR startup folder. However, I am not sure how to call this Br script once the application is open?
#target bridge
#engine main
app.bringToFront();
if ( BridgeTalk.appName == 'bridge' ) {
var toolMenu = MenuElement.find( 'Tools' ),
ojo = new MenuElement( 'command', 'Remove All Collections', '-at the end of toolMenu', 'ojodegato001');
};
ojo.onSelect = function () { removeAllCollections(); }
function removeAllCollections() {
var collects = app.getCollections();
for ( var i = collects.length-1; i >= 0; i-- ) {
app.deleteCollection( collects );
};
};
OK if you add this one to you user scripts folder… It should give you a NEW custom option at the end of the tools menu… Click n run there…
Already have an account? Login
No account yet? Create an account
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.