shash_bro
10-15-2009, 03:30 PM
It's a Windows 2003 domain, and regular users don't have write
permissions to program folders. We have certain batch files on the
server used to map network drives which run when user logs in. In
active directory these batch files are specified on User->properties-
>profile tab. I have included this cmd in a batch file 'xcopy s:\xyz\*.nfo files c:
\program files\xyz /D /Y', where S: is the network drive, latest files
are copied from S: to C:, and this command fails when normal users
login because they don't have write permissions to the c:\program files
\xyz folder.
Can we switch user just to run that copy command ... something like
runas or switch user cmd. I tried runas but it prompts for password
which obviously a normal user cannot know and doesn't have to enter.
Is there any other way to do this ... I'm sure there is? Please help.
permissions to program folders. We have certain batch files on the
server used to map network drives which run when user logs in. In
active directory these batch files are specified on User->properties-
>profile tab. I have included this cmd in a batch file 'xcopy s:\xyz\*.nfo files c:
\program files\xyz /D /Y', where S: is the network drive, latest files
are copied from S: to C:, and this command fails when normal users
login because they don't have write permissions to the c:\program files
\xyz folder.
Can we switch user just to run that copy command ... something like
runas or switch user cmd. I tried runas but it prompts for password
which obviously a normal user cannot know and doesn't have to enter.
Is there any other way to do this ... I'm sure there is? Please help.