Ex. My Drifblim with Aftermath uses explosion on Heracross. Will Aftermath activate?
I think not because when Drifblim uses explode when it has aftermath it doesn't work. It only works when it doesn't kill the pokemon. I know because that happened to me in black and white. If Drifblim is knocked out by a Direct Attack, the attacker is damaged by 1/4 its maximum HP. That is from here http://pokemon.marriland.com/ it proves that the attacker has to kill it
Actually, if you use explosion and the pokemon doesn't faint, aftermath does some extra damage. So if your pokemon uses explosion against Steelix, and it only does half it's HP, aftermath should do a little extra damage to cut it's HP to 25%.