With the basic tool of the powerful secondary development function of UG NX and based on the analysis of the characteristics of typical mechanical parts, put forward a digital method and system of parametric design for the parts, created the relavent parts-library for the system. In the parametric design, mechanical parts were divided roughly into four classes according to GT. The characteristic parameters were selected from the shared attributes of each class. By utilizing the secondary development tool of UG/Open, compiled, connected by means of Visual C++, and realized the integration of a mechanical-part orientated UG system for parametric design with user-friendly interface and counterpart dynamic-link library files. Taking characteristic parameters of typical parts as the variables, different models were established through man-computer interaction according to size constraint, and then created the parts-library. The system has worked successfully taking the inner gear as example of the typical part, and given expected result. It is shown from the execution of system that the current system with the virtual parts-library can respond the designer's demand fast, avoid repetition, save manpower and time, and improve the speed of new product development significantly.