A numerical solution of the nonlinear Schrödinger (NLS) equation is obtained by using the quadratic B-spline finite element method. Test problems concerning motion, birth and bound states of solitons of the NLG equation are studied to evaluate the method. Results are compared with various numerical methods.