Ejemplo n.º 1
0
        private void _timer_Tick(object sender, EventArgs e)
        {
            _timer.Stop();

            //Initialiser Liste "Flux"
            dgv_ConnexionEnCours.AutoGenerateColumns = false;
            dgv_ConnexionEnCours.DataSource          = new BindingList <Transfert>(TransfertsService.getTransfertsEtat("En cours"));

            dgv_ConnexionEnCours.SelectionMode = DataGridViewSelectionMode.FullRowSelect;

            _timer.Start();
        }
Ejemplo n.º 2
0
        public HeliosTransfertServeur()
        {
            InitializeComponent();

            //Initialiser Timer
            _timer.Tick += _timer_Tick;
            _timer.Start();

            //Initialiser Liste "Connexion en Cours"
            dgv_ConnexionEnCours.AutoGenerateColumns = false;
            dgv_ConnexionEnCours.DataSource          = new BindingList <Transfert>(TransfertsService.getTransfertsEtat("En cours"));

            DataGridViewCell cell = new DataGridViewTextBoxCell();

            dgv_ConnexionEnCours.Columns.Add(new DataGridViewColumn()
            {
                CellTemplate = cell, Name = "codeFlux", DataPropertyName = "codeFlux", HeaderText = "Code Flux"
            });
            dgv_ConnexionEnCours.Columns.Add(new DataGridViewColumn()
            {
                CellTemplate = cell, Name = "codeTransfert", DataPropertyName = "codeTransfert", HeaderText = "Code Transfert"
            });
            dgv_ConnexionEnCours.Columns.Add(new DataGridViewColumn()
            {
                CellTemplate = cell, Name = "designation", DataPropertyName = "designation", HeaderText = "Désignation"
            });
            dgv_ConnexionEnCours.Columns.Add(new DataGridViewColumn()
            {
                CellTemplate = cell, Name = "ipSource", DataPropertyName = "ipSource", HeaderText = "Ip Source"
            });
            dgv_ConnexionEnCours.Columns.Add(new DataGridViewColumn()
            {
                CellTemplate = cell, Name = "etat", DataPropertyName = "etat", HeaderText = "Etat"
            });
            dgv_ConnexionEnCours.Columns.Add(new DataGridViewColumn()
            {
                CellTemplate = cell, Name = "dateTransfert", DataPropertyName = "dateTransfert", HeaderText = "Date Transfert"
            });

            FormClosing += HeliosTransfertServeur_FormClosing;
        }