Preheat the oven to 400 degrees F (200 degrees C). Unfold puff pastry sheets, and place flat onto baking sheets. Bake for 10 to 15 minutes, or until lightly browned and puffed. Set aside.
Combine the sugar, custard powder and cornstarch in a large saucepan. Mix in just enough milk to form a paste, then gradually mix in the rest. This will prevent lumps from forming. Add the butter. Cook over medium heat, stirring frequently until thick. You may need to use a whisk to ensure a smooth consistency. When the mixture comes to a simmer, cook stirring constantly for 2 minutes. Remove from the heat, and stir in the egg yolks and vanilla.
Line a 9 inch baking dish with aluminum foil. Place one of the baked pastry sheets in the bottom of the dish. Spread the custard filling in an even layer over the pastry, and top with the other sheet.
Mix the confectioners’ sugar with 1 tablespoon of milk, and a dash of vanilla to make an icing. Spread over the top of the pastry. Refrigerate until the custard layer is firm. Remove from the pan and slice.