1. maybe .ex4 callable windows i/f codes to give cmd to so can do DOS stuff and get maybe into file then u read...
2. maybe .dll better way? not big code, for those in know ;)
i add below - is link to thread talk maybe interest?
Writing a dll for this wouldn't be that hard.
Don't know if I have the time right now to do so though.
You are wanting the internet IP of the machine correct?
Don't need to write a dll, just call the Window's DLL (winsock.dll)
You'll have to create a #import and functions to properly access the data. Compare the kernal32 GetTimeZoneInformation definitions with the attached (pre-Build 600) TimeGMT
The local machine doesn't necessarily know its IP address. If it is behind something like a normal domestic broadband router doing NAT, then the router has a public IP address but all the computers sitting behind it only have private and non-unique addresses such as 192.168.0.123.
There's nothing you can query on the local machine which is guaranteed to give you a public IP address. (Stringo's suggestion above about ipconfig is similarly wrong; on a computer such as the one I'm using to type this, ipconfig will only tell you the private non-unique address allocated to the machine, not the public address assigned to the router).
The only easy way of getting the IP address is to bounce a message off a server on the internet: e.g. do a WebRequest to a server which responds with the IP address it is getting called from. In other words, do a WebRequest to something similar to http://www.whatsmyip.org/, but better designed for automated processing of the response.
The simple answer is to lock against an account number, not a computer (or variants such as providing unfettered use on demo accounts, but requiring a licence for live accounts).
If you really want to lock against the hardware, then it's the same answer as https://www.mql5.com/en/forum/128665. It's a compromise between security and simplicity. Something like GetVolumeInformation() is easy to implement, but also creates a fairly easy way for someone to share a valid licence with other people/computers. (What's changed since https://www.mql5.com/en/forum/128665 is that MQL4 code is now much harder to decompile.)