Exemplo n.º 1
0
        private void AfficheListeAction()
        {
            tabAction.Controls.Clear();

            var ctrllisteaction = new ctrlListeAction();

            ctrllisteaction.Acces   = Acces;
            ctrllisteaction.DP      = DP;
            ctrllisteaction.Console = Console;
            ctrllisteaction.Chemin  = Chemin;

            ctrllisteaction.Afficher_ListeAction();

            ctrllisteaction.Dock = DockStyle.Fill;

            tabAction.Controls.Add(ctrllisteaction);
        }
Exemplo n.º 2
0
        public void Afficher_GestionAction()
        {
            DockContent D_Gestion = new DockContent();

            ctrlListeAction ctrl = new ctrlListeAction();

            ctrl.Acces   = Acces;
            ctrl.DP      = Acces.DP;
            ctrl.Chemin  = Acces.CheminTemp;
            ctrl.Console = Acces.Console;

            ctrl.Dock = DockStyle.Fill;
            ctrl.Afficher_ListeAction();
            D_Gestion.Controls.Add(ctrl);

            D_Gestion.Show(Acces.DP, DockState.DockLeft);
            D_Gestion.Text          = "Gestion des actions";
            D_Gestion.Tag           = "GESTION_ACTION";
            D_Gestion.ShowInTaskbar = false;
            D_Gestion.CloseButton   = true;
        }
Exemplo n.º 3
0
        void Ouvrir_Element_Appel_Externe()
        {
            foreach (string f in System.IO.Directory.GetFiles(Chemin + "\\Fichiers", "EXT_*.*"))
            {
                try {
                    string cmd     = System.IO.File.ReadAllText(f);
                    string element = cmd.Split(':')[0].ToUpper().Trim();
                    string id      = cmd.Split(':')[1];

                    switch (element)
                    {
                    case "PLAN":
                    {
                        CAPA.Interfaces.ctrlListePlan ctrl = new ctrlListePlan();
                        ctrl.Acces   = Acces;
                        ctrl.DP      = DP;
                        ctrl.Chemin  = Chemin;
                        ctrl.Console = Console;
                        ctrl.plan    = (Plan)Acces.Trouver_Element(Acces.type_PLAN, int.Parse(id));
                        ctrl.Ouvrir_Plan();
                        break;
                    }

                    case "OBJECTIF":
                    {
                        CAPA.Interfaces.ctrlListeObjectif ctrl = new ctrlListeObjectif();
                        ctrl.Acces   = Acces;
                        ctrl.DP      = DP;
                        ctrl.Chemin  = Chemin;
                        ctrl.Console = Console;
                        ctrl.obj     = (Objectif)Acces.Trouver_Element(Acces.type_OBJECTIF, int.Parse(id));
                        ctrl.Modifier_Objectif();
                        break;
                    }

                    case "ACTION":
                    {
                        CAPA.Interfaces.ctrlListeAction ctrl = new ctrlListeAction();
                        ctrl.Acces   = Acces;
                        ctrl.DP      = DP;
                        ctrl.Chemin  = Chemin;
                        ctrl.Console = Console;
                        ctrl.action  = (CAPA.Classes.Action)Acces.Trouver_Element(Acces.type_ACTION, int.Parse(id));
                        ctrl.Modifier_Action();
                        break;
                    }

                        /*case "INDICATEUR":
                         *  {
                         *      CAPA.Interfaces.ctrlListeIndicateur ctrl = new ctrlListeIndicateur();
                         *      ctrl.Acces = Acces;
                         *      ctrl.DP = DP;
                         *      ctrl.Chemin = Chemin;
                         *      ctrl.Console = Console;
                         *      ctrl.indicateur = (Indicateur)Acces.Trouver_Element(Acces.type_INDICATEUR, int.Parse(id));
                         *      ctrl.Ouvrir_Indicateur();
                         *      break;
                         *  }*/
                    }
                    //Suppression du fichier de commande externe
                    System.IO.File.Delete(f);
                } catch { }
            }
        }