Jump to content
Server Maintenance This Week. ×

SystemIpAddress getting the correct one


trevix

This topic is 4321 days old. Please don't post here. Open a new topic instead.

Recommended Posts

I have limited knowledge of Ethernet and TCP/IP so you will excuse my ignorance...

I have FileMaker Pro 12 that host a file on OSX.

I need to get, on the hosting FileMaker Pro, the ip address of this same computer.

On the network preference of the Mac I've IPv4: 192.168.1.130 (the router is 192.168.1.254)

This is the IP that I need to get in my calculation...but:

On the sharing of FM I have 10.0.2.1; 192.168.1.130

A get(SystemIpAddress) gives me:

10.0.2.1

192.168.1.130

192.168.238.1

192.168.93.1

I could easily pull the second line from the list, but this list seems to change often (the 10.0.2.1 wasn't there a few days ago). For example on the VMware Windows 7 partition of the same machine, the function gives me 192.168.1.132 (that is correct), without other values on the list.

On another Mac on the same intranet I get 192.168.1.135 (correct). One value only.

Since this is going to be a solution to be sold, I need a way to nail it down...

I feel that this is related to DNS, but this info does not help me.

Thanks for reading.

Trevix

Link to comment
Share on other sites

Hi there,

the other IPs are the ones created by VMWare for the virtual adapters. Anyway, there could be other reasons to see more than one value.

I have a similar test running in my solutions :

I suggest you create a field in some parameter table, e.g. "RouterIP".

That field could be set once and for all when the DB admin "installs" the file. (that is, opens it for the first time on that machine)

Then you should be able to easily retrieve the correct value by somehow filtering the IP list, comparing values against the first 3 groups of figures of the router's IP (including the 3rd dot) : 192.168.1.

The only difference is that I'm hosting the DB vith FMS, so I'm not running the test against a "user defined RouterIP field", but against the HostIP returned by FileMaker (which would probably not be helpful for you).

Link to comment
Share on other sites

That field could be set once and for all when the DB admin "installs" the file. (that is, opens it for the first time on that machine)

I thougth about this, but most of my potential clients will find the search for the Ip number too cumbersome...(in my opinion).

I must explain that I have an external application that acts as a web server, to wich from FileMaker I send URL's, so I need both to nail the correct IP.

The fact is that both the OSX network preferences and Win7 lan setup show the correct IP. And a shell call on the PC at least put the correct one in top of the listed.

I wonder if using applescript (shell) and vbscript from Filemaker I could isolate the IP that I need...instead of using get(SystemIpAddress).

A similar problem is getting the NIC address (I would like to use it to do licence checking).

Filemaker report 2 NIC address, the first for the WiFi card and the second for the Ethernet card, without being able to tell wich is wich.

In my external app, I do a shell call (en0 or en1) and I get the wright one (I hope this would be consistent on any PC...)

Link to comment
Share on other sites

This topic is 4321 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.