Exemplo n.º 1
0
        private void SaveButton_Click(object sender, RoutedEventArgs e)
        {
            c.Description = DescriptionTextBox.Text;

            if (EventID == null)
            {
                Context.Event.Add(c);
            }

            Context.SaveChanges();

            if (parent != null)
            {
                parent.UpdatePage();
            }

            this.Close();
        }
Exemplo n.º 2
0
        private void SaveButton_Click(object sender, RoutedEventArgs e)
        {
            c.Name        = NameTextBox.Text;
            c.Appearance  = ApearanceTextBox.Text;
            c.Description = DescriptionTextBox.Text;

            if (CharID == null)
            {
                Context.Character.Add(c);
            }

            Context.SaveChanges();

            if (parent != null)
            {
                parent.UpdatePage();
            }

            this.Close();
        }