logon script problem after desktop folder redirect in terminal server

hi,
i have a terminal server that i want to initiate desktop folder redirect.
server os: 2003
i set it up in the gpo and it works ,
the problem now is that i have a logon script that copy shortcuts to users desktop folder ->
xcopy \\server\netlogon\shortcuts\"blabla.lnk" "%userprofile%\desktop" /D /Y
after redirecting the logon script is not working -> i understand why but i can`t figure our how to fix it..
is there any enviorment variable that correspond to the desktop folder ?
any %desktop% or smt like that ?

thanks in advance
Udi
FiremanFpGAsked:
Who is Participating?
 
WindowsITAdminConnect With a Mentor Commented:
Hi.
Here you have all the environment variables http://vlaurie.com/computers2/Articles/environment.htm
There is not someting like %Desktop% but you can make a script that checks if the session is at the Terminal Server by reading the Computer Name and make something like
If ComputerName=TerminalServer then
      xcopy \\server\share\blbla.lnk c:\users\\desktop
Else
     xcopy \\server\netlogon\shortcuts\"blabla.lnk" "%userprofile%\desktop" /D /Y
End if

Hope this helps
0
 
Jordie77Connect With a Mentor Commented:
Can't you use the redirected location? Like: \\server\redirectdir\%userprofile%\desktop ?
0
 
FiremanFpGAuthor Commented:
first of all thanks for the answers,
what i did is for my easy of usage i created an enviorment called %homedesktops% and i set the value for the \\server\desktoptargetdir
and changed the script to point to %homedesktops%\%username%\desktop

thanks for the answers
:)

udi
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.