This is often given in the death-chamber of the Christian believer; and not only to him, when dying, but to those who are eye-witnesses of the mode of his departure.
I never have had anything to do with the Evangelicals while living, and they shan't come near me when dying.
But we live, when dying; we outlive death, and live for ever.
The prodigies of their bravery at last succeeded in arresting the progress of the enemy, and the last who fell in this hardly-contested battle had the consolation, when dying, to see the Saracens fly.
Tillotson, when dying, thanked his Maker that he felt his conscience at ease, and that he had nothing further to do but to await the will of Heaven.
Cardinal Wolsey, when dying, by slow progress and short journeys, reached Leicester Abbey.
The above list will hopefully provide you with a few useful examples demonstrating the appropriate usage of "when dying" in a variety of sentences. We hope that you will now be able to make sentences using this group of words.