To understand the event "Ted was dying.  Ted wrote a will.", it is important to know that Will is a written document to be used after one dies.