HELP! with AS3 Variables


I have a button in flash, which in as2 i defined as:
_root.btnStats = btnStats;

Then when clicked the as2 was:

and the URL was simply passed in Via Ajax/Flash Variables.

Unfortunately this is no longer working in AS3 and I have been searching for a solution for hours now.

Can anyone help me out? How to do the same thing but written for AS3??