This depends on the country you are travelling to. In principle, if you are already in the EU or the United Kingdom, you can travel on to a Schengen country or another country in the EU. But you will need to meet the entry conditions for that country.
If you are travelling via the Netherlands to another Schengen country where an entry ban applies, you must be able to show proof when transiting through the Netherlands that you can enter that country.