Page 1 of 1

Phidget22.Net & NetServerAddedEventArgs / NetServerRemovedEventArgs

Posted: Mon Jul 03, 2023 9:53 am
by Steve
Is it expected behavior that the value of the HostName property changes between the ServerAdd (NetServerAddedEventArgs.HostName) & ServerRemoved (NetServerRemovedEventArgs.HostName) events on a Wireless VINT Hub
HUB5000_0?

For example, I can observe the HostName changes from 'hub5000-01.local.' during the ServerAdded event to 'hub5000-01' during the ServerRemoved event.

Phidget22 - Version 1.15 - Built Jun 16 2023 14:03:46 / 1.15.20230616 / .NET 7.0

Re: Phidget22.Net & NetServerAddedEventArgs / NetServerRemovedEventArgs

Posted: Tue Jul 04, 2023 10:46 am
by Patrick
That's correct, we don't try to do a resolve on mDNS remove because there's a good chance it will fail, so the hostname, address and port are not available. If you want to match up server added and removed events, you should use the name field.

As for why the hostname has been set to the name in the remove event - I'm not exactly sure.

-Patrick