예제 #1
0
        public ViewFeat(Feat feat)
        {
            InitializeComponent();

            this.feat = feat;

            tbName.Text   = feat.GetName();
            tbPrereq.Text = feat.GetPrereq();

            rtbDesc.Document.Blocks.Clear();
            rtbDesc.Document.Blocks.Add(new Paragraph(new Run(feat.GetDesc())));
        }
예제 #2
0
 private void cbFeat_SelectionChanged(object sender, SelectionChangedEventArgs e)
 {
     try
     {
         Feat temp = (Feat)cbFeat.SelectedItem;
         tbPrereq.Text = temp.GetPrereq();
         rtbDesc.Document.Blocks.Clear();
         rtbDesc.Document.Blocks.Add(new Paragraph(new Run(temp.GetDesc())));
     }
     catch (Exception error)
     {
         MessageBox.Show(error.Message);
         throw;
     }
 }