Thanks for your effort!
Unfortunately doesn't work it...
I want to explain the situation more detailed:
When the client starts his application, he get's a login-dialog, where he has to type in the servername (and username, password ....) he wants to connect to. When the client types in a servername, that does not exist or the server is not available, he must get a new chance to login, without restarting his application.
When he clicks the Login-Button I do something like this:
Dispather MyDispatcher;<br />
MyDispatcher=new Dispatcher();<br />
If an error occures (severname incorrect or server not available) I have to unregister this Dispather-object first, before I can register it again with another URL.
RemotingServices.Disconnect(Dispatcher) does not work, because it's for Serverobjects. And Reregistering (with
RegisterWellKnownClient) throws an exception ("System.Runtime.Remoting.RemotingException: Es wurde versucht, die bereits umgeleitete Aktivierung des Typs 'Dispatcher, ccShared' erneut umzuleiten.").
What can I do?
Thanks in advance!