public void MyClickEvent(object sender, EventArgs e) { // events from the view if (sender == view.getBtn1()) { //MessageBox.Show("This click was on button:" + ((Button)sender).Text + view.getBtn1()); GenericRepository <Breed> repos = new GenericRepository <Breed>(); Breed dog = new Breed(); dog.Breed1 = "dog"; dog.BreedID = 56; dog.FoodCostPerKG = 45; dog.HousingCosts = 67; dog.SpeciesID = 6; repos.insert(dog); repos.save(); } else if (sender == view.getBtn2()) { MessageBox.Show("This click was on button:" + ((Button)sender).Text + view.getBtn2()); } }
partial void UpdateBreed(Breed instance);
partial void DeleteBreed(Breed instance);
partial void InsertBreed(Breed instance);