The loop() function is called in an endless loop, for the for loop will be executed every time. Typically, if you want something done once, you put that code in setup().
You could create a global flag:
bool beenThereDoneThat = false;
Then, in loop:
if(!beenThereDoneThat)
{
digitalWrite(dirpin, LOW); // Set the direction.
delay(2000);
for (i = 0; i<25; i++) // Iterate for 25 microsteps.
{
digitalWrite(steppin, LOW); // This LOW to HIGH change is what creates the
digitalWrite(steppin, HIGH); // "Rising Edge" so the easydriver knows to when to step.
delayMicroseconds(200); // This delay time is close to top speed for this
} // particular motor. Any faster the motor stalls.
beenThereDoneThat = true;
}