What is the .NET method to have access to a RO interface locally

What is the .NET variant for the delphi THYLocalService class?

I want to connect to a RO interface which is hosted in this EXE.

I found LocalClientChannel in the documentation but this does not work

Here’s what I tried:
var localClientChannel = new RemObjects.SDK.LocalClientChannel();
var clientBinMessage = new RemObjects.SDK.BinMessage();
var itf=OffCloudServerData.CoSyncServerService.Create(clientBinMessage, localClientChannel);
When I try to use the itf I get exception ‘No Server assigned.’

This is the sample code:

            var localServerChannel = new LocalServerChannel();

            var localChannel = new LocalClientChannel();
            localChannel.Server = localServerChannel;

            var message = new BinMessage();

            var loginSvc = CoLoginService.Create(message, localChannel);
            loginSvc.Login("A", "A");

            var service = CoService1.Create(message, localChannel);
            var result = service.DoSomething("test");

            MessageBox.Show($"Result: {result}");

When I try this I get
RemObjects.SDK.Exceptions.ServerSetupException: ‘No dispatchers configured for this server.’

(already on the Login function call)

Note: The code is in a C# .NET DLL (should it matter).

You need to register a dispatcher in the LocalServerChannel instance. In the recent Remoting SDK builds this is done automatically. Older ones require one additional line of code:

            var localServerChannel = new LocalServerChannel();
            localServerChannel.Dispatchers.Add("bin", new BinMessage());

            var localChannel = new LocalClientChannel();
            localChannel.Server = localServerChannel;

            var message = new BinMessage();

            var loginSvc = CoLoginService.Create(message, localChannel);
            loginSvc.Login("A", "A");

            var service = CoService1.Create(message, localChannel);
            var result = service.DoSomething("test");

            MessageBox.Show($"Result: {result}");

This appears to work, thanks