Until 13 December 2016 you were only eligible for a residence permit or temporary status if the medical treatment you required to avoid a medical emergency did not exist in your country of origin. IND did not research whether you would actually have access to the treatment. For instance, it did not matter if you could not afford the treatment.
This changed on 13 December 2016. On that day the European Court of Human Rights delivered a significant judgment in the case of a Georgian man (Paposhvili) vs. Belgium. This ruling is of importance to the situation in the Netherlands.
Barbara Wegelin wrote an article about the consequences of this ruling. Read it here (opens pdf, in Dutch).
On 11 April 2017, the State Secretary for Security and Justice sent a letter to the House of Representatives, in which he explains the changes he wants to make in the policy for medical residence permits for it to be in accordance with the Paposhvili ruling.
The accessibility of treatment in your country of origin now needs to be included by IND in the decision whether you may stay in the Netherlands for medical treatment.
It is up to you to prove that you do not have access to treatment: because treatment options are limited, treatment is too expensive; the hospital is too far, etcetera.
Based on this information, IND will decide whether you may stay in the Netherlands for treatment, or, if you have to return to your country of origin, which conditions must be met to effect such a return.