Do you mean the name of the computer that the app is running on?
[red]"... isn't sanity really just a one trick pony anyway?! I mean, all you get is one trick, rational thinking, but when you are good and crazy, oooh, oooh, oooh, the sky is the limit!" - The Tick[/red]
yes, an app is running on each server. there are two app servers which are managed by load balancing. for ex, if server 1 issued an error to the user then the vb app will pass a value such as "AppServer1" and the error number to the database.
my other option is to have a server name constant, but my manager wants to minimize hard coded values.
I'm not currently running a server OS so I'm not sure which of the Environment Variables you would need. To find out, open a Cmd window and type Set and press enter. This will list all the Environment variables on the machine, one of them will be the computer's name (on XP Pro its COMPUTERNAME). In your program you just need to use the Environ(VariableName) function to get the information.
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.