We define work as the net force multiplied with the distance traveled. We already know distance to be 2 meters. Thus, all we need to know is the net force.
When dealing with multiple forces acting on a body, it is advisable to draw a free-body diagram like that shown in the picture. There are three forces acting on the box: gravitational force pointing straight down, normal force perpendicular to the slope denoted as Fn and the frictional force acting opposite to the direction of motion of the box denoted as Ff. Frictional force is equal to coefficient of kinetic friction (μk) multiplied with Fn.
∑Fy = Fn - mgcos30° = 0
Fn = (10)(10)(cos 30) = 86.6 N
∑Fx = μk*Fn - mgsin30° = Fnet
(0.2)(86.6 N) - (10)(sin30°) = Fnet
Fnet = 12.32 Newtons
Thus,
W = Fnet*d
W = (12.32 N)(2 meters)\
W = 24.64 Joules