How do I embed ROZeroConfHub in the application

According to http://www.remobjects.com/changelogs.aspx?id={943D3312-98FA-42C9-B2F7-ABFD8E6AFE3F}

The enhancement “32356: Option to embed ROZeroConfHub in the application” is really great for my purpose: deploying and launching an application using ZeroConfig without much hassle in detecting the local server. However, I can’t seem to locate documentation on how to embed ROZeroConfHub in the application. Any pointer?

You can read about this in our wiki http://wiki.remobjects.com/wiki/ZeroConf

Slava: that topic doesn’t really answer the question (although it sure should be expanded to do so… :wink:

So apparently I was going the wrong direction, ROZeroConfHub is only to be run on the server machine? Can’t find anywhere if this is also supossed to be run on the client machine as well or not. I found (through your class documentation) about TROZeroConfRegistration.AutoStartZeroConfHub, which is great, it will launch ROZeroConfHub automatically on the server!

However, ROZeroConfHub continues to run even after the application is closed. Should I be closing this manually (searching for the form and closing it with my own code), or leaving it running? I understand that there could be other applications using ROZeroConfHub on the server that I am not aware of, so it would be best to keep it running imo.

Yes. Zeroconf hub needs to run in both client and server, and it’s best to consider this a system level service and keep it running.

Ron Grove has a basic tutorial how to embed ROZeroConf in a application.
http://techblog.rongrove.com/2009/12/basic-delphi-remobjects-dataabstract.html