This work is an example of application of nonlinear programming to a problem of three-dimensional trajectory optimization for multistage launch vehicles for geostationary orbit missions. The main objective is to minimize fuel consumption or equivalently to maximize the payload. The launch vehicle considered here, Europa-II, consists of 5 thrust phases and 2 coast phases. Major parameters of the coast arcs such as inclination, eccentricity and true anomaly of attachment points are not prespecified and should be found in optimization problem. The fairing should be jettisoned whenever aerothermal flux falls below a certain value. An aerodynamic heating constraint for atmospheric part of the flight is also considered. The problem is solved by direct collocation method and results are compared with those in Ref.  where an indirect multiple shooting method with an inner loop for parameter optimization is used. Advantages of present work with respect to methods used in that reference are then discussed.