コード例 #1
0
        private void Window_Loaded(object sender, RoutedEventArgs e)
        {
            //preenche o drop down com os personagens q tem o user com adm==true
            //!!!!!!!!!!!!!
            //trocar ara isso dps
            comboBox.ItemsSource = PersogemDAO.returnPAdm();
            //comboBox.ItemsSource = PersogemDAO.RetornarPersonagens();
            comboBox.DisplayMemberPath = "Nome";
            comboBox.SelectedValuePath = "IDPesonagem";

            if (comboBox.Items.IsEmpty)
            {
                comboBox.IsHitTestVisible = false;
                btnVCadastrar.IsEnabled   = false;
            }
        }
コード例 #2
0
        private void Window_Loaded(object sender, RoutedEventArgs e)
        {
            comboBox.ItemsSource = PersogemDAO.returnPAdm();
            //comboBox.ItemsSource = PersogemDAO.RetornarPersonagens();
            comboBox.DisplayMemberPath = "Nome";
            comboBox.SelectedValuePath = "IDPesonagem";

            txtNome.Text  = m.Name;
            txtDescr.Text = m.Descricao;
            txtExp.Text   = m.ExperienciaConcedida.ToString();
            txtGold.Text  = m.GoldConcedido.ToString();
            if (comboBox.Items.IsEmpty)
            {
                comboBox.IsHitTestVisible = false;
                btnVCadastrar.IsEnabled   = false;
            }
        }
コード例 #3
0
 private void Window_Loaded(object sender, RoutedEventArgs e)
 {
     dtg.ItemsSource  = PersogemDAO.RetornarPersonagensDeUsuarios();
     dtg2.ItemsSource = PersogemDAO.returnPAdm();
 }