|
Home > Archive > IIS ASP > September 2004 > Getting the user's machine name
You are viewing an archived Text-only version of the thread.
To view this thread in it's original format and/or if you want to reply to
this thread please [click here]
| Author |
Getting the user's machine name
|
|
| Scott McNair 2004-09-23, 5:54 pm |
| How would I go about extracting an end-user's machine name? I tried
finding the info in server variables but it wasn't there. Or would this be
a client-side solution instead? If it is, I apologize for posting to the
wrong group.
Regards,
Scott
| |
| Curt_C [MVP] 2004-09-23, 5:54 pm |
| It's not unique so it's not often used, nor is it recommended.
I do believe it's in the Request.ServerVariables() though....
--
Curt Christianson
Owner/Lead Developer, DF-Software
Site: http://www.Darkfalz.com
Blog: http://blog.Darkfalz.com
"Scott McNair" <scott.mcnair@sfmco.takethispartout.com> wrote in message
news:Xns956D70375AEF0sfmco@207.46.248.16...
> How would I go about extracting an end-user's machine name? I tried
> finding the info in server variables but it wasn't there. Or would this
> be
> a client-side solution instead? If it is, I apologize for posting to the
> wrong group.
>
> Regards,
> Scott
| |
| Aaron [SQL Server MVP] 2004-09-23, 5:54 pm |
| The server can't access this unless it is offered, via
Request.ServerVariables("REMOTE_HOST"). Anyway this will almost always be
the network name, not the actual machine name. I think you will have to
rely on a signed applet or ActiveX control, and yes, it would have to happen
on the client.
I thought I had a FAQ on this, but can't seem to locate it.
--
http://www.aspfaq.com/
(Reverse address to reply.)
"Scott McNair" <scott.mcnair@sfmco.takethispartout.com> wrote in message
news:Xns956D70375AEF0sfmco@207.46.248.16...
> How would I go about extracting an end-user's machine name? I tried
> finding the info in server variables but it wasn't there. Or would this
be
> a client-side solution instead? If it is, I apologize for posting to the
> wrong group.
>
> Regards,
> Scott
| |
| Patrice 2004-09-23, 5:54 pm |
| More likely you'll have an IP address available in server variables and it's
hidden etc by firewalls and such...
Explaining the overall goal may lead to better suggestions...
Patrice
--
"Scott McNair" <scott.mcnair@sfmco.takethispartout.com> a écrit dans le
message de news:Xns956D70375AEF0sfmco@207.46.248.16...
> How would I go about extracting an end-user's machine name? I tried
> finding the info in server variables but it wasn't there. Or would this
be
> a client-side solution instead? If it is, I apologize for posting to the
> wrong group.
>
> Regards,
> Scott
| |
| Scott McNair 2004-09-23, 5:54 pm |
| "Patrice" <nobody@nowhere.com> wrote in
news:uZcmK$YoEHA.1176@TK2MSFTNGP12.phx.gbl:
> More likely you'll have an IP address available in server variables
> and it's hidden etc by firewalls and such...
>
> Explaining the overall goal may lead to better suggestions...
I'm writing an administrative piece for an intranet app we have, that
allows an administrator to add new machines to our DB. If the admin is
running the app from the new machine, I was wanting to have the machine
name and IP auto-populated for him in the form, so he wouldn't have to hunt
down the info and enter it manually (also the person doing admin may not be
technically inclined).
| |
| Aaron [SQL Server MVP] 2004-09-23, 5:54 pm |
| I don't think you'll be able to get the machine name information from ASP...
--
http://www.aspfaq.com/
(Reverse address to reply.)
"Scott McNair" <scott.mcnair@sfmco.takethispartout.com> wrote in message
news:Xns956D7DB0CD13Fsfmco@207.46.248.16...
> "Patrice" <nobody@nowhere.com> wrote in
> news:uZcmK$YoEHA.1176@TK2MSFTNGP12.phx.gbl:
>
>
> I'm writing an administrative piece for an intranet app we have, that
> allows an administrator to add new machines to our DB. If the admin is
> running the app from the new machine, I was wanting to have the machine
> name and IP auto-populated for him in the form, so he wouldn't have to
hunt
> down the info and enter it manually (also the person doing admin may not
be
> technically inclined).
| |
| Patrice 2004-09-23, 5:54 pm |
| Try http://component-dll.aspobjects.com...ts/network/dns/
For an Intranet you should read back something quite meaningfull.
We have done something similar (but was using ASP.NET using a class readily
available) to identiy the machine from which a problem is declared...
If this is to keep and uptodate listing of all stations it could be likely
done from a central location (kind of inventory). For example if all
machines are registered in your domain, it's likely you could get them all,
or at logon time etc...
Patrice
--
"Scott McNair" <scott.mcnair@sfmco.takethispartout.com> a écrit dans le
message de news:Xns956D7DB0CD13Fsfmco@207.46.248.16...
> "Patrice" <nobody@nowhere.com> wrote in
> news:uZcmK$YoEHA.1176@TK2MSFTNGP12.phx.gbl:
>
>
> I'm writing an administrative piece for an intranet app we have, that
> allows an administrator to add new machines to our DB. If the admin is
> running the app from the new machine, I was wanting to have the machine
> name and IP auto-populated for him in the form, so he wouldn't have to
hunt
> down the info and enter it manually (also the person doing admin may not
be
> technically inclined).
| |
| Scott McNair 2004-09-23, 5:54 pm |
| "Aaron [SQL Server MVP]" <ten.xoc@dnartreb.noraa> wrote in
news:u80wuJZoEHA.2900@TK2MSFTNGP12.phx.gbl:
> I don't think you'll be able to get the machine name information from
> ASP...
I'm starting to discover that myself, by digging thru websites related to
it. It appears the tentative solution is to have a client-side script that
calls a WSH object, which would pop up the "Some objects may be harmful"
warning, but since this is the intranet that may be okay.
|
|
|
|
|