I know that AutoCAD has the extreme trim command which enables you to trim everything either inside or outside a boundary line.

Has anyone put together a routine that will delete everything either inside or outside a specified boundary line?