示例#1
0
        private void LoadUserFriends()
        {
            friendDataGrid.Items.Clear();
            List <Classes.User> newObject = query.GetFriends();

            foreach (Classes.User item in newObject)
            {
                Classes.User friend = query.GetUserDetails(item.user_Id);
                friendDataGrid.Items.Add(friend);
            }
        }
示例#2
0
        private void LoadUserFriends()
        {
            friendDataGrid.Items.Clear();
            List <Object[]> newObject = query.GetFriends();

            foreach (Object[] item in newObject)
            {
                Classes.User friend = query.GetUserDetails(item[0].ToString());
                friendDataGrid.Items.Add(friend);
            }
        }
示例#3
0
 private void LoadUserDetails()
 {
     if (userListBox.SelectedIndex > -1)
     {
         Classes.User currUser = query.GetUserDetails(userListBox.SelectedItem.ToString());
         nameTextBox.Text    = currUser.username;
         starsTextBox.Text   = currUser.average_stars.ToString();
         fansTextBox.Text    = currUser.fans.ToString();
         yelpingTextBox.Text = currUser.yelping_since.ToString();
         funnyTextBox.Text   = currUser.funny.ToString();
         coolTextBox.Text    = currUser.cool.ToString();
         usefulTextBox.Text  = currUser.useful.ToString();
         latTextBox.Text     = currUser.user_latitude.ToString();
         longTextBox.Text    = currUser.user_longitude.ToString();
         query.SetCurrentUser(currUser);
     }
 }