Werbung: SecurityConsole.de verwaltet Ihre Computer mit Security Essentails aus der Cloud!
30 Tage kostenfrei testen und 20% Rabatt für Ihre Bestellung mit Promocode: WBF2685582
(Promocode gültig bis 31.12.2011)

Group:  English: Windows Server » microsoft.public.windows.server.scripting
Thread: Script based on Connecting Client IP Windows Terminal Server

HTVi
TV Discussion Newsgroups

Script based on Connecting Client IP Windows Terminal Server
"entsupport" <u46980[ at ]uwe> 10/17/2008 3:24:00 PM
Hey I got a good scripting question for you gurus out there. We are trying to
write a script that will copy certain files to a user desktop when they log
onto a Windows Terminal server. Sounds easy but does anyone know how you can
check against a clients connecting IP address. We have a multi site practice
and each location has there own perscription printer within there site. If
someone travels between locations they have to maually select the printer for
that location within our practice management software. We are able to have
ini files that will populate the default printer based on location but we
need to know what office they are connecting from so that the system knows
which file to copy over.

The issue is how can windows tell what client machine is conected to the
terminal server so we can have the proper files copied for that location.

Thanks in advance for any help provided.

Re: Script based on Connecting Client IP Windows Terminal Server
"Al Dunbar" <AlanDrub[ at ]hotmail.com.nospaam> 10/17/2008 9:13:14 PM

"entsupport" <u46980[ at ]uwe> wrote in message news:8bce696d82375[ at ]uwe...
[Quoted Text]
> Hey I got a good scripting question for you gurus out there. We are trying
> to
> write a script that will copy certain files to a user desktop when they
> log
> onto a Windows Terminal server. Sounds easy but does anyone know how you
> can
> check against a clients connecting IP address. We have a multi site
> practice
> and each location has there own perscription printer within there site. If
> someone travels between locations they have to maually select the printer
> for
> that location within our practice management software. We are able to have
> ini files that will populate the default printer based on location but we
> need to know what office they are connecting from so that the system knows
> which file to copy over.
>
> The issue is how can windows tell what client machine is conected to the
> terminal server so we can have the proper files copied for that location.
>
> Thanks in advance for any help provided.
>

try running this script from a terminal services session to see if it gives
you what you need:

[ at ]echo off

if /i "%clientname%" EQU "Console" (
echo/you are logged in to %computername% at the console
) else (
echo/you are logged in to %computername% from %clientname%
)

/Al


Home | Search | Terms | Imprint Contact
Newsgroups Reader - provided by WiredBox.Net
Suche nach Orten, Städten, Postleitzahlen, Vorwahlen, Kfz-Kennzeichen