Instantiate problem.

hello guys,
I doing some games jus like practicing cricket. Where a machine have to throw the ball and the user to bat it. but im facing problem in the machine. The machine throws only one ball. I tried the instantiate method inside update and called inside for loop. but its not working inside update function. When i execute the instantiate method outside the function its working fine. So can you explain me whats wrong.

thanks in advance
K.Karthik

thanks for the idea... here i post my script and guys help me out.

var speed = 10;
var i ;

var projectile : Rigidbody ;
var instantiatedProjectile1 : Rigidbody;

function Start()
{
    Debug.Log("WELCOME");
    hello();
}
function hello()
{
    for(i=0;i>2;i++)
    {
        Debug.Log("ball");

        var instantiatedProjectile1 : Rigidbody = Instantiate( projectile, transform.position, transform.rotation );
        //instantiatedProjectile1.name ="coconut";
        instantiatedProjectile1.rigidbody.velocity = transform.TransformDirection( Vector3( 0, 0, -speed ) ); 
        Physics.IgnoreCollision( instantiatedProjectile1.collider, transform.root.collider, true );
    }
}

yes actually i want balls one from one. and i tried in all ways but its not working. but in this code above, only one ball is jus bouncing up and down near the machine.