Variable not Assigned

Hi there,

I have a problem with a variable. Unity says its not assigned, but I have assigned in the inspector. In my opinion everything is correct. I don’t see a mistake. I have tried everythng: reassigning the variable, renaming the variable - nothing works. Anyone an Idea?
Here is my code - maybe there is the mistake:

var cubePrefab : Transform;
var numberOfCubes :int =10; //number of Cubes needed in this level

function Start()
	var cube = new Array();
	for(var i=0;i<numberOfCubes; i++)
		Instantiate(cubePrefab, Vector3 (2*i, 0.5, 0), Quaternion.identity);

Ok, thanks for the Answers, I think I have a solution now!