# Delete an mc with a button press?

**URL:** https://forum.kirupa.com/t/delete-an-mc-with-a-button-press/274684
**Category:** flash
**Created:** [November 3, 2008, 3:12am UTC](https://forum.kirupa.com/t/delete-an-mc-with-a-button-press/274684 "2008-11-03T03:12:14Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![Shred49](https://avatars.discourse-cdn.com/v4/letter/s/ed655f/32.png) [@Shred49](https://forum.kirupa.com/u/Shred49)
#### Post date: [November 3, 2008, 3:12am UTC](https://forum.kirupa.com/t/delete-an-mc-with-a-button-press/274684/1 "2008-11-03T03:12:14Z")

</div>

how come this isn’t working?

```auto
on(release){
    _root.terrain.clear = true;
}

```

“terrain” is the line that is drawn by the mouse and i want to make a button with AS to delete the lines when pressed.
