Get port the app is running on - possible?

I’m tinkering with some code and wonder if there is a way inside of xojo to get the port the app is started on from a shell script?

For example in a bash script:
./myApp --port=9000

Then inside xojo get the port
Var myRunningPort As Integer
myRunningPort = ???


I’m assuming this is a web application in which case you can use app.Port and/or app.SSLPort. See

Thanks Wayne. I have so many iterations of my program that I couldn’t find it earlier. I opened an older version and saw that I had actually put a comment in about it but didn’t use it. So I just found it and came back to answer my own question, but you beat me to it. Thank you for the help. :slight_smile: