A DNR order should be considered when a cancer patient's prognosis is poor, and the likelihood of recovery is minimal. It is particularly relevant for patients in the advanced stages of cancer, where the focus shifts from curative treatment to palliative care. Discussions about DNR should be initiated early, allowing patients and their families ample time to understand and make informed decisions.