private void lkupItem_SelectedObjectChanged(object sender, EventArgs e) { UCustomerSelection control = this; if (control.OnChanged != null) { control.OnChanged(control, null); } if (lkupItem != null) { updateObject(); } }
private void cbxEnable_Unchecked(object sender, RoutedEventArgs e) { UCustomerSelection control = this; if (control.OnChanged != null) { control.OnChanged(control, null); } MPackageCustomer v = (MPackageCustomer)CustomerSelected; if (v == null) { return; } v.EnabledFlag = "N"; }
private void cboSelectionType_SelectionChanged(object sender, SelectionChangedEventArgs e) { UCustomerSelection control = this; if (control.OnChanged != null) { control.OnChanged(control, null); } ComboBox cbo = sender as ComboBox; if (lkupItem != null) { lkupItem.Lookup = LookupSearchType2.CustomerGroupLookup; lkupItem.SelectedObject = null; } if (cbo.SelectedIndex == 0) { lkupItem.Lookup = LookupSearchType2.CustomerTypeLookup; lkupItem.Caption = CLanguage.getValue("customer_type"); } else if (cbo.SelectedIndex == 1) { lkupItem.Lookup = LookupSearchType2.CustomerGroupLookup; lkupItem.Caption = CLanguage.getValue("customer_group"); } else if (cbo.SelectedIndex == 2) { lkupItem.Lookup = LookupSearchType2.CustomerLookup; lkupItem.Caption = CLanguage.getValue("customer"); } lkupItem.SelectedObject = null; updateObject(); }