Get task id corresponding to the timer event task

I think you may find your answer in this thread.