yam yam vapi smaran bhavam
tyajaty ante kalevaram
tam tam evaiti kaunteya
yam yam—whatever; va—either; api—also; smaran—remembering; bhavam—nature; tyajati—give up; ante—at the end; kalevaram—this body; tam tam—similar; eva—certainly; eti—gets; kaunteya—O son of Kunti; sada—always; tat—that; bhava—state of being; bhavitah—remembering.
Whatever state of being one remembers when he quits his body, that state he will attain without fail.
The process of changing one's nature at the critical moment of death is here explained. How can one die in the proper state of mind? Maharaja Bharata thought of a deer at the time of death and so was transferred to that form of life. However, as a deer, Maharaja Bharata could remember his past activities. Of course the cumulative effect of the thoughts and actions of one's life influences one's thoughts at the moment of death; therefore the actions of this life determine one's future state of being. If one is transcendentally absorbed in Krsna's service,then his next body will be transcendental (spiritual), not physical. Therefore the chanting of Hare Krsna is the best process for successfully changing one's state of being to transcendental life.
Link to this page: http://prabhupadabooks.com/bg/8/6