 | How to register a chanel |
| //// formatter setting
| | BinaryServerFormatterSinkProvider objServerFormat = new BinaryServerFormatterSinkProvider();
| | objServerFormat.TypeFilterLevel = System.Runtime.Serialization.Formatters.TypeFilterLevel.Full;
| |
| | BinaryClientFormatterSinkProvider objClientFormat = new BinaryClientFormatterSinkProvider();
| |
| | //// port setting
| | System.Collections.IDictionary _props = new System.Collections.Hashtable();
| | _props["port"] = 8002;
| |
| | //// Chanel creation
| | HttpChannel chan = new HttpChannel(_props, objClientFormat, objServerFormat);
| | ChannelServices.RegisterChannel(chan);
| |
|