private void CreateControls() { this.lblServiceType = new FormLabel(0, "lblServiceType", false, "lbl_tour_type"); this.lblServiceName = new FormLabel(1, "lblServiceName", false, "lbl_service_name"); this.lblServicePrice = new FormLabel(2, "lblServicePrice", false, "lbl_price"); this.cbxServiceTypes = new ComboBox(); this.tbxServiceName = new TextBox(); this.mpkBasePrice = new MoneyPicker(); }
public FrmTourPriceEditor(Entities.TourBasePrice price) : this() { this.price = price; this.tbxTourType.DataBindings.Add( new Binding( "Text", this.price.TourType, "Name", false, DataSourceUpdateMode.OnPropertyChanged, string.Empty, string.Empty, null)); this.mpkBasePrice = new Presentation.Controls.MoneyPicker(); this.mpkBasePrice.Anchor = AnchorStyles.Top | AnchorStyles.Left | AnchorStyles.Right; this.tlpMain.Controls.Add(this.mpkBasePrice, 1, 1); this.mpkBasePrice.Value.Currency = this.price.PricePerPerson.Currency; this.mpkBasePrice.ValueEditor = Convert.ToString(this.price.PricePerPerson.Value); }