We have studied systems of dipolar soft spheres in a confined slab geometry: the system is confined between two parallel walls (separated by a finite width) and is periodic in the other two directions. We were interested in the energetically most favorable configurations at zero temperature at constant number density. In order to find the particle configurations corresponding to the global minimum in the relevant thermodynamical potential, we have used an optimization tool based on ideas of genetic algorithms. For a correct treatment of the long-ranged dipolar interactions, energy calculations were carried out employing the method of Ewald sums. We have investigated confined systems of soft spheres both with and without dipole moment. In addition, we have also studied the effects of an external field perpendicular to the walls. We have identified the complex intermediate phases as the system creates, with increasing slab width, several interesting buckling structures.