private void button1_Click(object sender, EventArgs e) { Attraction a; if (attr.vid == 0) { a = new Attraction(); } else { a = attr; } AttractionType attractiontype = comboBox1.SelectedIndex == (int)AttractionType.Viewport ? AttractionType.Viewport : comboBox1.SelectedIndex == (int)AttractionType.Vechicle ? AttractionType.Vechicle : comboBox1.SelectedIndex == (int)AttractionType.Nature ? AttractionType.Nature : AttractionType.Building; a.SetName(textBoxNameAttraction.Text); a.SetLongitude(float.Parse(textBoxLongitudeAttraction.Text)); a.SetLatitude(float.Parse(textBoxLatiudeAttraction.Text)); a.vtype = attractiontype; TripsService.AppFiles.Database.DbService.Update<Attraction>(a); }
public virtual void SetAtractions(Attraction atractions) { this.atraction = atractions.vid; }
public void SetAtractions(Attraction[] atractions) { this.atractions = atractions; }
public void SetAtractions(Attraction[] atractions) { throw new System.Exception("Not implemented"); }
public AttractionEdiorForm(Attraction attr) { // TODO: Complete member initialization this.attr = attr; InitializeComponent(); }