In this particular case, L = w, so V = hw^2.
The total surface area SA is the sum of the areas of all six faces, or SA = 2Lw + 2Lh + 2hw. Since L = w, then:
SA = 2w^2 + 4wh = 240
Solve the above for h in terms of w.
Plug the result into the "volume" formula. This will allow you to find an expression for the volume in terms only of w.
(Since you haven't been given enough information, there is no way to find the numerical value of the volume.)