Пример #1
0
        public BlankPage()
        {
            this.InitializeComponent();

            client = new SQLWebProxyClient();
            client.RemoteAddress = "localhost";
            client.RemotePort = 8080;
        }
Пример #2
0
        public MainWindow()
        {
            InitializeComponent();

            TestSerialize();

            this.Closing += (s, e) =>
                {
                    server.Stop();
                };

            // NOTE: The constructor of SQLWebProxy uses default settings. You might want to
            // override these and should edit the .config file to provide valid settings here
            server = new SQLWebProxy(Properties.Settings.Default.ServerAddress, Properties.Settings.Default.ServerUsername,
                Properties.Settings.Default.ServerPassword, Properties.Settings.Default.ServerDatabase, Properties.Settings.Default.ServerPort);
            server.OnLogOutput += (line) =>
                {
                    Dispatcher.Invoke(new Action(() =>
                        {
                            textBox1.Text += line + "\r\n";
                        }));
                };

            Properties.Settings.Default.RemoteAddress = "localhost";
            Properties.Settings.Default.RemotePort = 8080;

            // NOTE: You should edit the .config file to provide valid settings here
            client = new SQLWebProxyClient();
            client.RemoteAddress = Properties.Settings.Default.RemoteAddress;
            client.RemotePort = Properties.Settings.Default.RemotePort;
        }