示例#1
0
 void UCCategoryPicker_Loaded(object sender, RoutedEventArgs e)
 {
     Loaded        -= new RoutedEventHandler(UCCategoryPicker_Loaded);
     categoryFacade = new CategoryFacade(CPApplication.Current.CurrentPage);
     BindingControl();
     InitializeCategoryComboBox();
 }
        void UCPrimaryCategoryPicker_Loaded(object sender, RoutedEventArgs e)
        {
            CategoryList = new List <CategoryInfo>();

            categoryFacade = new CategoryFacade(CPApplication.Current.CurrentPage);
            queryFilter    = new CategoryQueryFilter()
            {
                CompanyCode = "8601"
            };
            InitializeCategoryComboBox();

            //Loaded -= new RoutedEventHandler(UCPrimaryCategoryPicker_Loaded);
            //var exp = this.GetBindingExpression(UCPrimaryCategoryPicker.CategorySysNoProperty);
            //if (exp != null && exp.ParentBinding != null)
            //{
            //    string path = exp.ParentBinding.Path.Path;
            //    Binding binding = new Binding();
            //    binding.Path = new PropertyPath(path);
            //    binding.Mode = BindingMode.TwoWay;
            //    binding.NotifyOnValidationError = true;
            //    cmbCategory.SetBinding(Newegg.Oversea.Silverlight.Controls.Combox.SelectedValueProperty, binding);
            //}
        }
示例#3
0
 void UCCategoryQuery_Loaded(object sender, RoutedEventArgs e)
 {
     categoryFacade          = new CategoryFacade(CPApplication.Current.CurrentPage);
     queryFilter.CompanyCode = "8601";
     InitializeCategoryComboBox();
 }