You can take some shortcuts. For example, 2 is the only even prime. Treat it as a special case, start with 3, and increment the possible prime by 2 every time. You can start your checks with n % 3 instead of n % 2 (% is the modulus operator, which returns the remainder of an integer division, for those who are confused). Of course, if this is a homework assignment, you may be docked points for hard coding 2 like this. If, on the other hand, you just want to find primes, this step will save some time.
It isn't necessary to check to see if the possible prime is evenly divisible by every number less than itself. It's impossible for a number n to be evenly divisble by a number greater than n/2. Also, since you're skipping all the even numbers in the first place, you don't have to check past n/3. It may be possible to trim down the possibilites more if you put more thought into it.
This is right off the top of my head, so I may have overlooked something: