How and when does one become an heir or legatee?

In the Netherlands, no provision is made for any court procedure.
However, there is an instrument, the declaration of inheritance (Verklaring van Erfrecht), see Article 4:188 BW, issued by the Dutch notary (see Article 3:31 BW) to all parties concerned, namely the heirs.
The executor of the will can also ask for a declaration of inheritance. In the declaration of inheritance, the notary, because of his authority, names the persons who are entitled to the inheritance, their share in the inheritance and, if applicable, the name of the executor. By means of the declaration of inheritance, the heirs/executor can identify themselves to the debtors of the estate and they will be able to obtain disposal of the bank balances, etc.
A notarial deed is necessary for the transfer of immovable property or a right in an immovable property to one of the heirs.