velocity issue on pushing an object forward.

I am making a object throwing script and have an issue:

“velocity” is not a member of UnityEngine.GameObject

Here is my script.

Grenade.velocity = transform.TransformDirection( Vector3( 0, 0, ThrowPower) );

Grenade is a GameObject and velocity has to be accessed through the rigidbody of the gameobject.
Make sure your grenade object has a rigidbody component attached and then use this instead:

Grenade.rigidbody.velocity = transform.TransformDirection( Vector3( 0, 0, ThrowPower) );