Web-based distance learning programs are widely available. A few distance education platform and standards were developed or proposed. Among current software systems, it is hard to realize a strategic assessment of courseware quality. Since one of the difficulties of distance education is the load that an instructor needs to spend in courseware design, it is worthy to investigate an automatic mechanism to help an instructor to produce effective courseware. Thus, a distance learning program can proceed efficiently. We develop a mechanism for the construction of courseware structure based on the influence diagram. The mechanism can be implemented as a decision support system for the instructor to analyze the relation among course units and test units. The overall value of a courseware can be systematically analyzed.