Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: edits/style
Scripting_function


Panel
titleDescription

Returns the IP address of the computer that the script was ran on. When run in the Gateway scope, returns the Gateway IP address. When run in the Client scope, returns the Client IP address.

Client permissions restrictions


Panel
titleSyntax

system.net.getIpAddress()

  • Parameters

noneNothing

  • Returns

String - Returns the IP address of the local machine, as it sees it.

  • Scope

Gateway, Vision Client, Perspective Session

Panel
titleCode Examples
Code Block
languagepy
titleCode Snippet
# Put this script on a navigation button to link dedicated machines to specific screens.
ip = system.net.getIpAddress()
# checkCheck which line this client is tied to.
if ip == "10.1.10.5":
   system.nav.swapTo("Line Detail", {"line":1})
elif ip == "10.1.10.6":
   system.nav.swapTo("Line Detail", {"line":2})
else:
   system.nav.swapTo("Line Overview")
Panel
titleKeywords

system net getIpAddress, net.getIpAddress