Jump to content

Recommended Posts

Hi There,

I have created a tool which will copy the files from one of the share location to another shared location. What i mean is , i have a share location where i have only read access not right access. so i decided to run the robocopy with parameters by using RunAs() function. For your reference i have the function below which is there in my code.

Global $Devsource =serversharedrive
Global $QADest = server1sharedrive
$Batch = RunAs($SID, "Domain", $SPass, 2, "c:tempROBOCOPY.EXE " & '"' & $Devsource & $SplitData[5] & '"' & " " & '"' & $QADest & $Namelog[1] & '"' & " " & "/MIR /E /TEE /log+:c:V" & $Namelog[1] & ".log", "", @SW_SHOW)


That $SplitData[5] will contain the folder name. if i run the tool in client machine this Function works without any issue. But if i run the same code in Virtual Machine it does not work it simply skips... :)

I thought it may be because of domain name difference... but we have created trust relationship. so it should work as per my knowledge..

Any clue for this?

The reason for trying the tool in Virtual machine not in client is, if i run the tool from client that takes very huge time to complete the file copy. so i thought the virtual machines hardware and entire stuffs near to the server... so i thought running the tool in Virtual machine may copy the files so fast...

do you have any suggestion to make the copy process fast in client machine?

Sorry for the poor English ;)

Edited by Syed23

Thank you,Regards,[font="Garamond"][size="4"]K.Syed Ibrahim.[/size][/font]

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    No registered users viewing this page.

  • Create New...