Introduction
ConnectivityService ServerUri could be used to verify what server you are connected to. You can also verify that you still are connected to the server.
Code Sample
# Copyright © 2019. TIBCO Software Inc. Licensed under TIBCO BSD-style license. from Spotfire.Dxp.Framework.ApplicationModel import ConnectivityService connectivity= Application.GetService[ConnectivityService]() # In 10.4+ Document.Properties["myProperty"] ="Public Server URI: " + str(connectivity.ServerPublicUri) Document.Properties["myProperty"] +="\nInternal Server URI: " + str(connectivity.ServerInternalUri) # Obsolete, but still availiable # Document.Properties["myProperty"] ="Server: " + str(connectivity.ServerUri) Document.Properties["myProperty"] += "\nConnected: " + str(connectivity.IsOnline)
References
License: TIBCO BSD-Style License
Recommended Comments
There are no comments to display.