protected void Page_Load(object sender, EventArgs e)
        {
            FacebookConnect fbConnect = new FacebookConnect();
            if (fbConnect.IsConnected)
            {
                Facebook.FacebookAPI api = new Facebook.FacebookAPI(fbConnect.AccessToken);
                JSONObject me = api.Get("/" + fbConnect.UserID);
                facebookName = me.Dictionary["name"].String;
                lblInfo.Text = "Hello " + facebookName + "<br>" + "<br>";

                JSONObject f = api.Get("/me/friends");
                KeyValuePair<String, JSONObject> friends = f.Dictionary.ElementAt(0);

                for (int i = 0; i < friends.Value.Array.Count(); i++)
                {
                    lblFriends.Text = lblFriends.Text + "Friend #" + i.ToString() + " | ";
                    JSONObject friend = api.Get("/" + friends.Value.Array[i].Dictionary["id"].String);

                    lblFriends.Text = lblFriends.Text + friend.Dictionary["name"].String + ",  ";

                    lblFriends.Text = lblFriends.Text + friend.Dictionary["link"].String;

                    lblFriends.Text = lblFriends.Text + "<br>";
                }
            }
            else
                lblInfo.Text = "Please Login First!";
        }
 protected void Page_Load(object sender, EventArgs e)
 {
     FacebookConnect fbConnect = new FacebookConnect();
     if (fbConnect.IsConnected)
     {
         Facebook.FacebookAPI api = new Facebook.FacebookAPI(fbConnect.AccessToken);
         JSONObject me = api.Get("/" + fbConnect.UserID);
         facebookName = me.Dictionary["name"].String;
         lblName.Text = "Hello " + facebookName;
     }
 }
 protected void Page_Load(object sender, EventArgs e)
 {
     FacebookConnect fbConnect = new FacebookConnect();
     if (fbConnect.IsConnected)
     {
         Facebook.FacebookAPI api = new Facebook.FacebookAPI(fbConnect.AccessToken);
         JSONObject me = api.Get("/" + fbConnect.UserID);
         facebookName = me.Dictionary["name"].String;
     }
     else
         lblInfo.Text = "Please Login First!";
 }