private void ExecuteEdit(object parameter)
        {
            int index = Users.IndexOf(parameter as User);

            if (index > -1 && index < Users.Count)
            {
                User = new User();
                User = Users[index];

                int i = 0;
                foreach (var item in availableQueries)
                {
                    if (item.idProfile == User.IdProfile)
                    {
                        Queries.MoveCurrentTo(availableQueries[i]);
                        break;
                    }
                    i++;
                }



                FAMA.AP.Model.Profile currentQuery = (FAMA.AP.Model.Profile)Queries.CurrentItem;
                currentQuery.idProfile   = User.IdProfile;
                currentQuery.ProfileName = User.ProfileName;
            }
        }
 void queries_CurrentChanged(object sender, EventArgs e)
 {
     FAMA.AP.Model.Profile currentQuery = (FAMA.AP.Model.Profile)Queries.CurrentItem;
     User.IdProfile   = currentQuery.idProfile;
     User.ProfileName = currentQuery.ProfileName;
 }