if you are sitting straight up and pressing either the DB, the machine, or barbell straight up then you were definitely working your shoulders. If you felt like you were working your back you're form is off.
other good shoulder exercises are upright rows, lateral and front raises, and bent over flies.