Flash game with facebook connect

hello,
Hi i made flash game in action script 3.0. In my game i have leader score… i have 2 buttons 1. share on facebook and 2. challenge your friends on facebook.
on clicking 1 button it will directly go to facebook and share my score on facebook.
And on clicking 2 button my all facebook friends pics will appear with checkbox when i am selecting few of my friends and click on go buttons, the facebook request will go to selected friends only for challenge … how to do this 2 buttons functionality. what i need to do

please help me
And i am so sorry for my bad English

thanks in advance…