keeping z positions fixed in a surface layer

Is it somehow possible to keep the z position fixed (partial constraint) for a surface layer of molecules during geometry optimisation (planar unit cell containing some molecules)? Is there at least a simple workaround for doing that? In surface science you often have the problem to find the geometry with the lowest energy for a planar surface layer, e.g. for a self-assembled planar structure. Unfortunately MaterialsStudio Forcite doesn't contain the feature for partial positional constraints anymore (I'm using MatStudio since Januar 07; before I used Cerius2 which offers this feature)