Method for producing an electronic assembly which is completely surrounded by at least two moulding materials and in the case of which electric contact elements are led as far as an outside of a shaped body formed from the moulding materials, having at least one electronic component (3, 4), comprising the steps: - inserting at least one electronic component (3, 4) into an opened mould, the at least one electronic component (3, 4) being a printed circuit board, a lead frame or a ceramic substrate with an upper side and an underside, - arranging a separating element in the mould, the separating element being placed against the electronic component (3, 4) or being fixed to the electronic component (3, 4) at one end and extending as far as a wall of the mould at the other end, and/or - arranging at least one guide element in the mould, - supplying at least a first moulding material and a second moulding material to a cavity in the mould, the first moulding material being different from the second moulding material, - the separating element providing a subdivision of the cavity in the mould and separates the first moulding material and the second moulding material from one another in a region between the upper side of the printed circuit board, the lead frame or the ceramic substrate and the mould wall and/or between the underside of the printed circuit board, the lead frame or the ceramic substrate and the mould wall, the separating element effecting sealing on the electronic component (3, 4) and the mould wall, and/or - the guide element permitting flow guidance of the first and second moulding material supplied, so that by mixing the first and second moulding material a mixing area is formed in defined subareas of the shaped body, and - closing the mould, - the mould being closed before or at the same time as the first and second moulding material (21, 22) are supplied. - inserting at least one electronic component (3, 4) into an opened mould, the at least one electronic component (3, 4) being a printed circuit board, a lead frame or a ceramic substrate with an upper side and an underside, - arranging a separating element in the mould, the separating element being placed against the electronic component (3, 4) or being fixed to the electronic component (3, 4) at one end and extending as far as a wall of the mould at the other end, and/or - arranging at least one guide element in the mould, - supplying at least a first moulding material and a second moulding material to a cavity in the mould, the first moulding material being different from the second moulding material, - the separating element providing a subdivision of the cavity in the mould and separates the first moulding material and the second moulding material from one another in a region between the upper side of the printed circuit board, the lead frame or the ceramic substrate and the mould wall and/or between the underside of the printed circuit board, the lead frame or the ceramic substrate and the mould wall, the separating element effecting sealing on the electronic component (3, 4) and the mould wall, and/or - the guide element permitting flow guidance of the first and second moulding material supplied, so that by mixing the first and second moulding material a mixing area is formed in defined subareas of the shaped body, and - closing the mould, - the mould being closed before or at the same time as the first and second moulding material (21, 22) are supplied.