private void mainTree1_OnSeleccion(object sender, DataEventArgs e) { if (e != null && (e.TipoElemento == TipoElemento.Expediente || e.TipoElemento == TipoElemento.Servicio)) { id_expediente = e.Id; Cursor = Cursors.WaitCursor; RemoteZeus.OnIdChanged(); Cursor = Cursors.Default; } }
private RemoteZeus StartRPCClient() { try { //ChannelServices.RegisterChannel(new HttpClientChannel("client_remotezeus_grifos", new SoapClientFormatterSinkProvider()), false); RemoteZeus rz = (RemoteZeus)Activator.GetObject(typeof(RemoteZeus), "http://localhost:9254/RemoteZeus"); return(rz); } catch { return(new RemoteZeus()); } }
public static RemoteZeus RemoteZeus;// = Client(); //public static LocalizacionGPS LocalizacionGPS = LocalizacionGPS.StartClient(); public static RemoteZeus Client() { try { ChannelServices.RegisterChannel(new TcpClientChannel("client_remotezeus", new BinaryClientFormatterSinkProvider()), true); RemoteZeus rz = (RemoteZeus)Activator.GetObject(typeof(RemoteZeus), "tcp://localhost:9254/RemoteZeus"); return(rz); } catch { return(new RemoteZeus()); } }