Hello SvaneSDU,
SHP format supports only instances of the same type: point, polyline or polygon, so to export all contour lines you need to save separately polygons and polylines, when using SHP format, since both types cannot be present in the same file.
Polygons are true polygons in this case: not polylines that have one vertex for it's start and another for it's end, that have exactly the same coordinates.