Dynamical collapses of magnetized molecular cloud cores are studied with magnetohydrodynamical simulations from the run-away collapse phase to the accretion phase. In the run-away collapse phase, a disk threaded by magnetic field lines is contracting due to its self-gravity and its evolution is well expressed by a self-similar solution. The central density increases greatly in a finite time scale and reaches a density at which an opaque core is formed at the center. After that, matter accretes to the newly formed core (accretion phase). In this stage, a rotationally supported disk is formed in a cloud core without magnetic fields. In contrast, the disk continues to contract in the magnetized cloud core, since the magnetic fields transfer angular momentum from the disk. Its rotation motion winds up the threading magnetic field lines. Eventually, strong toroidal magnetic fields are formed and begin to drive the outflow, even if there is no toroidal field component initially. Bipolar molecular outflows observed in protostar candidates are naturally explained by this model.