private async void rejectbtn_Click(object sender, RoutedEventArgs e)
 {
     Guest_FriendCircle inviteresponse = new Guest_FriendCircle();
     inviteresponse.status = "rejected";
     inviteresponse.CircleId = circle_id;
     inviteresponse.username = (String)ApplicationData.Current.LocalSettings.Values["name"];
     var json_inviteresponse = JsonConvert.SerializeObject(inviteresponse);
     await App.azure_rendezvous_mobile_service_3Client.InvokeApiAsync("processinvite", new JObject(new JProperty("json_inviteresponse", json_inviteresponse)));
 }
        private async void createcirclebutton_Click(object sender, RoutedEventArgs e)
        {
            String circleId = Guid.NewGuid().ToString();
            String circleName = circlenametxt.Text;

            FriendCircle friendcircle = new FriendCircle();
            friendcircle.CircleId = circleId;
            friendcircle.CircleName = circleName;

            List<Guest_FriendCircle> invitee_friendcirclelist = new List<Guest_FriendCircle>();

            foreach (Guest invitee in inviteelist)
            {
                Guest_FriendCircle guest_friendcircle = new Guest_FriendCircle();
                guest_friendcircle.username = invitee.name;
                guest_friendcircle.CircleId = circleId;
                guest_friendcircle.IsAdmin = false;
                guest_friendcircle.status = "not sent";
                invitee_friendcirclelist.Add(guest_friendcircle);
            }
            Guest_FriendCircle inviter = new Guest_FriendCircle(); 
            inviter.username=(String)ApplicationData.Current.LocalSettings.Values["name"];
            inviter.CircleId = circleId;
            inviter.IsAdmin = true;
            inviter.status = "not sent";
            invitee_friendcirclelist.Add(inviter);
            try
            {            
                var jsonfriendcircle = JsonConvert.SerializeObject(friendcircle);
                var jsoninviteefriendcirclelist = JsonConvert.SerializeObject(invitee_friendcirclelist);

               await App.azure_rendezvous_mobile_service_3Client.InvokeApiAsync("saveinvite",new JObject(new JProperty("jsonfriendcircle", jsonfriendcircle),new JProperty("jsoninviteefriendcirclelist",jsoninviteefriendcirclelist)));

            //    System.Diagnostics.Debug.WriteLine("response :" +response);
            } catch (MobileServiceInvalidOperationException ex) {
                System.Diagnostics.Debug.WriteLine("Exception is :" + ex.Message+"Response from server :"+ex.Response);

            }
        }