4-40-2, A try for FG is an attempt by a player to score 2 or 3 points by throwing the ball into a team's own basket. A player is trying for a goal when they have the ball and IN THE OFFICIAL'S JUDGMENT is throwing or ATTEMPTING to throw for goal. It is not essential that the ball leave the player's hand as a foul could prevent release of the ball.
And so can the rim.