2D mesh extrusion

Hello,
I created a 2D mesh and want to extrude it in 3D. On the right and left sides of the 3D extruded mesh, I want to mesh a right block and a left block. How can I make sure I have a single connected mesh at the end (the 3D extruded mesh + the left and right blocks)?
Thank you

the best way to go with is using a compound of the two blocks. check this simple example:
exampleExtrusion.hdf (1,4 MB)
regards.

Thank you for your reply. What I would like to know however is if there’s a possibility to generate a 2D mesh for a given surface, extrude the mesh ( not the geometry) and then mesh conformly a geometry that englobes the extruded mesh.

can you be more clear? like create a drawing of what you want?
if i understand correctly:
you have 3 solids:
2 blocks sharing a face inside another 3rd solid.
you want to do what I did but having a external mesh (3rd solid) that is conformal with the mesh of the 2 blocks?