static void Main() { Configuration config = ConfigurationManager.OpenExeConfiguration(ConfigurationUserLevel.None); KeyValueConfigurationCollection settings = config.AppSettings.Settings; DbConnection connection = DbConnection.FromConfig(settings); Server server = new Server(connection); ServerConnector connector = new ServerConnector(server); Client client = new Client(connector); Application.EnableVisualStyles(); Application.SetCompatibleTextRenderingDefault(false); Application.Run(new main(client)); }
public main(Client client) { this.Client = client; InitializeComponent(); }