Example #1
0
        private async void Window_Loaded(object sender, RoutedEventArgs e)
        {
            try
            {
                //_fileData = await DFile.GetData();
                _fileAllData = await DFile.GetAllData();

                _fileTypeData = await DFileType.GetData();

                _violationData = await DViolation.GetData();

                _creatPersonData = await DPerson.GetCreate();

                _creatPlaqueData = await DPlaque.GetCreate();
            }
            catch (Exception exception)
            {
                Utility.MyMessageBox("خطا در بانک اطلاعاتی", "خطا در دریافت اطلاعات\n" + exception.Message);
                Close();
                return;
            }
            //_fileSearchData = _fileData;
            _fileSearchAllData       = _fileAllData;
            CboFileType.ItemsSource  = _fileTypeData;
            CboViolation.ItemsSource = _violationData;
            DgdFile.ItemsSource      = _fileSearchAllData;
            BtnNew_Click(null, null);
        }
        private async void Window_Loaded(object sender, RoutedEventArgs e)
        {
            try
            {
                _fileAllData = await DFile.GetAllData();

                _creatPersonData = await DPerson.GetCreate();

                _creatPlaqueData = await DPlaque.GetCreate();
            }
            catch (Exception exception)
            {
                Utility.MyMessageBox("خطا در بانک اطلاعاتی", "خطا در دریافت اطلاعات\n" + exception.Message);
                Close();
                return;
            }
            _fileSearchAllData  = _fileAllData;
            DgdFile.ItemsSource = _fileSearchAllData;
            FileId = 0;
            New();
        }