A dynamic density functional theory for polymeric systems has been used to investigate the influence of surface fields on the morphology of thin films of asymmetric diblock copolymers, which form cylinders in a bulk system. We have found that noncylindrical structures become stable when one of the blocks is strongly attracted by the surfaces. When the interaction between the surface and the polymer was increased, two transitions occur: (a) from parallel oriented cylinders to parallel oriented perforated lamellae (C ¿ CL) and (b) from this perforated lamellae to lamellae (CL ¿ L). It has also been observed that the microstructure becomes much more sensitive to the film thickness in the case where the surfaces strongly attract one of the polymer blocks. The influence of the surfaces seems to be limited to a region with a size of the order of one domain-domain distance.