Animation clip does not exist?

I’m trying to make a door that opens upon getting near it and hitting a key. That’s done. But it tells me the following when I try to run it:

The animation state Open could not be
played because it couldn’t be found!
Please attach an animation clip with
the name ‘Open’ or call this function
only for existing animations.
DoorOpen:Update() (at

In case it helps, here’s the script:

var open : boolean;
var target : GameObject;
var Door : Animation;

function Update () {
if (Input.GetKeyDown("e")){
var distance = Vector3.Distance(target.transform.position, transform.position);
if (distance < 3){
if (open == false){
open = true;

I have no idea why. I have two animations defined (Idle and Open) and Idle is the default. When I tried it with Open as default, Auto off, and just Play();, it says there is no default.

You defined Animation as separate variable, and you must attach it in inspector. If the animations are on door itself, you can use