コード例 #1
0
        public AbstractService()
        {
            ConfigurableServiceHost host = OperationContext.Current.Host as ConfigurableServiceHost;

            if (host == null)
            {
                throw new ArithmeticException("Cannot find ConfigurableServiceHost in current operation context.");
            }

            _server = host.Tag as FormSOAPServer;
            if (_server == null)
            {
                throw new ArithmeticException("Cannot find FormSOAPServer in current operation context.");
            }
        }
コード例 #2
0
        private void buttonServer_Click(object sender, EventArgs e)
        {
            FormSOAPServer frm = new FormSOAPServer();

            frm.ShowDialog();
        }