Episerver - delete everything in media / blocks libraries -


i wondering if had good, , importantly - quick ways of deleting in blocks / media libraries without having go through every individual item, , moving trash.

this i've been having before importing fresh data site, way have found of doing efficiently put 1 folder sub folders within it, allows me delete folder , of contents. doesn't me current project have ton of assets don't want go through, moving etc..

i'm surprised there isn't way clear library, or select , move trash?

thanks, giuseppe

there no easy way gui, far know, have deletechildren method on icontentrepository. creating scheduled job or plugin should pretty straightforward.

icontentrepository _contentrepository; // whereever var blockroot = new contentreference(123); // whereever, i.e. property on startpage  _contentrepository.deletechildren(blockroot, true, accesslevel.noaccess); 

also, if on media data, remember run "remove abandoned blobs" scheduled job afterwards (unless it's autorunning on intervals) clear disk space.


Comments

Popular posts from this blog

c# - How to get the current UAC mode -

postgresql - Lazarus + Postgres: incomplete startup packet -

javascript - Ajax jqXHR.status==0 fix error -