Exemple #1
0
        public void ResetAll()
        {
            IgnoredRow = -1;
            ExcelColumnPositionService ExServiceNew = new ExcelColumnPositionService();

            ListExCol        = ExServiceNew.getListCol();
            ProgressbarValue = "0";
            LblProgress      = "0/0";
            TxbFileName      = string.Empty;
        }
Exemple #2
0
        private void StartUpInitializer()
        {
            this.SchoolClasses         = new string[] { "V", "VI", "VII", "VIII", "IX", "X", "XI", "XII" };
            this.Section               = new string[] { "A", "B", "C", "D", "E" };
            this.ClsIndex              = -1;
            this.SectionIndex          = -1;
            this.UnSelectedColumnIndex = -1;
            this.SelectedColumnIndex   = -1;
            this.SYear            = DateTime.Today.Year;
            this.EYear            = DateTime.Today.Year;
            this.Slist            = new List <Student>();
            PreFilteredList       = new List <Student>();
            this.FilteredList     = new List <Student>();
            this.ProgressbarValue = "0/0";

            ExcelColumnPositionService exService = new ExcelColumnPositionService();

            this.UnSelectedColumns = new ObservableCollection <string>(exService.GetColListForExport());
            this.SelectedColumns   = new ObservableCollection <string>();
            this.db             = new ExcelExportDb();
            this._flagCanExport = true;
            this.FilterCategory = "none";

            HsArtsSubs      = new string[] { "ARABIC", "ECONOMICS", "EDUCATION", "GEOGRAPHY", "PHILOSOPHY", "HISTORY", "POL. SC", "SOCIOLOGY" };
            HsSciSubs       = new string[] { "PHYSICS", "CHEMISTRY", "MATHEMATICS", "BIOLOGY" };
            HsActiveSubs    = new string[] { };
            HsSubIndex      = -1;
            StreamList      = new string[] { "ARTS", "SCIENCE" };
            StreamListIndex = -1;

            SubHsVisibility = System.Windows.Visibility.Hidden;

            this.MoveRightCommand     = new RelayCommand(this.MoveRight, this.CanMoveRight);
            this.MoveRightAllCommand  = new RelayCommand(this.MoveRightAll, this.CanMoveRightAll);
            this.MoveLeftCommand      = new RelayCommand(this.MoveLeft, this.CanMoveLeft);
            this.MoveLeftAllCommand   = new RelayCommand(this.MoveLeftAll, this.CanMoveLeftAll);
            this.BuildGridViewCommand = new RelayCommand(this.BuildGridView, this.CanBuildGridView);
            this.ExportCommand        = new RelayCommand(this.Export, this.CanExport);
        }
Exemple #3
0
        public ExcelEntryViewModel()
            : base()
        {
            ExService        = new ExcelColumnPositionService();
            ExcelEntryHelper = new ExcelEntryHelper();
            ListExCol        = ExService.getListCol();
            IgnoredRow       = 0;
            LblProgress      = "0/0";
            ProgressbarValue = "0";
            ClassesInSchool  = new string[] { "V", "VI", "VII", "VIII", "IX", "X", "XI", "XII" };
            // SectionsInClass = new string[] { "-not applicable-", "A", "B", "C", "D", "E" };
            SectionsInClass  = new string[] { "-not applicable-" };
            SessionStartYear = DateTime.Today.ToString("yyyy");
            SessionEndYear   = DateTime.Today.ToString("yyyy");
            ExDb             = new ExcelEntryDb();
            _flagCanInsert   = true;

            FileOpenCommand            = new RelayCommand(getExcelFile, CanFileBrowse);
            IncrementIgnoredRowCommand = new RelayCommand(IncrementIgnoredRow, CanIncrementIgnoredRow);
            DecrementIgnoredRowCommand = new RelayCommand(DecrementIgnoredRow, CanDecrementIgnoredRow);
            InsertDataCommand          = new RelayCommand(InsertData, CanInsertData);
            ResetCommand = new RelayCommand(ResetAll, CanReset);
            AbortCommand = new RelayCommand(Abort, CanAbort);
        }