示例#1
0
        public Server(System.ComponentModel.IContainer componets)
        {
            _components = componets;
            this._dsServer = new NationalInstruments.Net.DataSocketServer(this._components);
            ((System.ComponentModel.ISupportInitialize)(this._dsServer)).BeginInit();
            ((System.ComponentModel.ISupportInitialize)(this._dsServer)).EndInit();

        }
示例#2
0
        private void InitializeComponent()
        {
            this.components = new System.ComponentModel.Container();

            // Setup dataSocketServer
            this.dataSocketServer = new DataSocketServer(this.components);
            ((System.ComponentModel.ISupportInitialize)(this.dataSocketServer)).BeginInit();

            ((System.ComponentModel.ISupportInitialize)(this.dataSocketServer)).EndInit();

            try
            {
                if (!dataSocketServer.IsOpen)
                {
                    dataSocketServer.Start();
                }
            }
            catch (Exception ex)
            {
                MessageBox.Show(ex.Message);
            }
        }