var sidebar_align = 'right';
var content_container_margin = parseInt('290px');
var sidebar_width = parseInt('270px');
Unanswered: Determining a user's IP address in VBA
I am running networked multi-user database, I am trying to set it up so that when people first connect to the database it updates a table to basically give the current time and their IP address.
This will help me with troubleshooting because if there are any problems with the DB, I can go back and tell who was in it around the time the problem occured.
However, I can't figure out how to return the current IP address in VBA....is there a way?
well, that will let me look up the IP address for a computer based on their machine name, or look up a machine name based on an IP address, but based on what I can tell, it won't let me know what MY (aka the current user's) IP address is.
look closer. see the declare for apiGetHostName ? that's the one you'll need. retrieve the local machine name and resolve it with the other functions.
okay, I see the declare for the apiGetHostname, but I then do not see that function used anywhere in the code....I don't think I understand how to use it...
You can use it after fInitializeSockets as in:
dim strHostName as string * 256
like all the api functions using strings you need to supply it with a prefilled string.