Groups | Blog | Home
all groups > inetserver asp components > august 2003 >

inetserver asp components : Need help with AspExec and xcopy...



Tim
8/21/2003 2:33:30 PM
Jorgen,

You should review the Microsoft documents on impersonating
a user from ASP. This will enable you to perform the
desired task.

http://support.microsoft.com/default.aspx?scid=kb;EN-
US;248187

-Tim
[quoted text, click to view]
the AspExec component (desktop-shortcuts for a specific
user....)
[quoted text, click to view]
\\"&CLIENT1&"\c$\"documents and
settings"\"&signature&"\desktop\*.*
\\"&CLIENT2&"\c$\"documents and
settings"\"&signature&"\desktop\"
[quoted text, click to view]
Jorgen Gustafsson
8/21/2003 4:05:55 PM
Hello,
im trying to xcopy files from one client to another using the AspExec component (desktop-shortcuts for a specific user....)

<%
client1 = request.form("client1")
client2 = request.form("client2")
signature = request.form("signature")
Set Executor = Server.CreateObject("ASPExec.Execute")
Executor.Application = "xcopy \\"&CLIENT1&"\c$\&quot;documents and settings&quot;\"&signature&"\desktop\*.* \\"&CLIENT2&"\c$\&quot;documents and settings&quot;\"&signature&"\desktop\"
Executor.Parameters = ""
strResult = Executor.ExecuteDosApp
%>

Since the webserver running the command doesnt have local admin-rights
on the clients ill get the "Access denied" message...

Is it possible to pass the admin username and password with the copy-command or any other way to solve this....

All help appreciated

Regards Jorgen
AddThis Social Bookmark Button