private void btnAddMeasure_Click(object sender, RoutedEventArgs e)
 {
     CategorysManager mc=new  CategorysManager();
     ProductMeasure m = new ProductMeasure
     {
         ProMeasureType = MeasureTxtBox.Text,
         ProMeasureUnit = DescriptionTxtBox.Text
     };
     mc.AddMeasure(m);
        // CategorysManager.NewestMeasure = m;
     DialogResult = true;
     Close();
 }
        public ListSalesView(string animationName, TabHelper hlp)
        {
            InitializeComponent();
            _tabHlp = hlp;

            _supplierClient = new SuppliersManager();
            _purchaseClient = new PurchaseClient();
            EditPurchaseBtn.Visibility = Visibility.Collapsed;
            CancelPurchaseBtn.Visibility = Visibility.Collapsed;
            image1.Visibility = Visibility.Collapsed;
            image2.Visibility = Visibility.Collapsed;

            _purchaseDetailsManager = new PurchaseDetailsManager();
            cc = new CategorysClient();

            mc = new CategorysManager();
            if (string.IsNullOrEmpty(animationName)) return;
            Storyboard animation = (Storyboard)Application.Current.Resources[animationName];
            LayoutRoot.BeginStoryboard(animation);
        }