Piezo-driven needle valves are widely used in electronic packaging due to their fast response, high resolution and good dispensing consistency. However, the stable generation of high-viscosity droplets is one of the key issues to its packaging quality. To investigate the formation mechanism of the high-viscosity droplet. In this paper, a 2D finite element model of the drop-on-demand injection process of the high-viscosity droplet is established based on the level set method, the droplet formation and separation processes are numerically simulated, and the reliability of the simulation results is checked by comparing the outcomes with published data. Specifically, the detailed evolution of the high-viscosity droplet formation and separation process is gained by coupling the two-phase flow-level set method and the dynamic grid technique, and the pressure distribution in the injection chamber is further discussed and the effects of operating parameters on the droplet formation volume are examined. The results of the study show that the needle motion is the main factor of pressure fluctuations in the injection chamber. Moreover, we also found that among the parameters of needle stroke, nozzle diameter, supply pressure, fluid viscosity, and surface tension, the nozzle diameter has the most significant effect on droplet volume, while surface tension has the least effect on droplet formation.