コード例 #1
0
 public void PreencherListView()
 {
     lstViewVPN.Items.Clear();
     foreach (var vpns in VPNConnect.GetListaDeVPN())
     {
         lstViewVPN.Items.Add(vpns);
     }
     lstViewVPN.View                 = View.Details;
     lstViewVPN.Columns[0].Width     = lstViewVPN.Width;
     lstViewVPN.Columns[0].TextAlign = HorizontalAlignment.Center;
 }
コード例 #2
0
        private void StartInicialDoServico()
        {
            if (Configuracoes.RequerConfigurar())
            {
                frmMain f = new frmMain();
                f.ShowDialog(this);
            }

            vpnMonitorada = new VPNConnect(Configuracoes.NomeConexaoVPN,
                                           Configuracoes.QuantidadeDePingsQuedaConexao,
                                           Configuracoes.QuantidadeDePingsParaDisparar,
                                           Configuracoes.IntervaloEntrePings,
                                           Configuracoes.ReconectarVPN,
                                           Configuracoes.NomeOuEnderecoIP);
        }