Ejemplo n.º 1
0
 //this method takes in a monster class that allows editing of its name and description only
 public NewMonsterPage(Monster edit)
 {
     InitializeComponent();
     monAccess      = new MonstersDBDataAccess();
     Title          = "Change Monster details";
     Monsters       = edit;
     BindingContext = this;                      //bind to display the current details
 }
Ejemplo n.º 2
0
 MonstersDBDataAccess monAccess;                 //start a database access
 public NewMonsterPage()
 {
     InitializeComponent();
     monAccess = new MonstersDBDataAccess();     //intialize the database
     Title     = "New Entry";                    //bind from xaml page
     Monsters  = new Monster                     //intialize a new monster
     {
         Name        = "Name of Monster",
         Description = "I am a gruesome detail of a monster."
     };
     BindingContext = this;                      //bind it to our xaml page
 }
Ejemplo n.º 3
0
 public MonstersPage()
 {
     InitializeComponent();
     //initializing
     this.DNDDatabase = new MonstersDBDataAccess();
 }
Ejemplo n.º 4
0
 public MonsterDetailPage(MonsterDetailViewModel monModel)
 {
     InitializeComponent();
     DNDDatabase    = new MonstersDBDataAccess();
     BindingContext = this.MonsterModel = monModel;
 }