Do not know how to run forward the dc motors.

But how to sets the motor to forward?

Really? It's a direction pin. It can be set HIGH or LOW. HIGH sets the motor direction to backwards. Try the alternative option.