Answer
The magnitude of the frictional force on the block is $~~10~N$
Work Step by Step
Let "down" be the positive direction.
We can consider the vertical forces on the block to find the required magnitude of the force of static friction $F_f$ to keep the block stationary:
$\sum F_y = 0$
$mg-P-F_f = 0$
$F_f = mg-P$
$F_f = 22~N-12~N$
$F_f = 10~N$
The magnitude of the frictional force on the block is $~~10~N$