If this is setup for remote operation un hook the cables and try to shift at the motor.
Does the prop turn by hand in neutral? In forward and reverse it should turn about 1/3 of the turn in gear.
If someone removed the pivot pin bolt in the gear case and didn't get it back in right it won't shift.
When trying to shift with the motor off you may have to move the prop by hand to mesh the dogs.
Does it pump water?