September 1, 2004 at 9:58 am
Hi There,
I have an activeX task which I'm trying to use to copy an .bcp text file from one share to antoher directory.
The script is as follows:
'**********************************************************************
' Visual Basic ActiveX Script
'************************************************************************
Function Main()
Dim FSO,SourceShare,WorkingDir
Set FSO=CreateObject("Scripting.FileSystemObject")
SourceShare = DTSGlobalVariables("strNewProducts").Value
WorkingDir = DTSGlobalVariables("strWorkingDir").Value
FSO.CopyFile SourceShare, WorkingDir
Main = DTSTaskExecResult_Success
End Function
However, when I try to run it I get the following error:
VB Runtime error
Permission Denied.
I've tried checking the shares involved and making sure the agent's account has full permissions without any joy.
Can anyone else suggest what the problem might be.
Cheers,
Jay.
September 1, 2004 at 3:33 pm
Jay,
Do both the SourceShare and WorkingDir contain a fully qualified path and filename?
September 2, 2004 at 6:37 am
Are you running the package under a domain account? If you are crossing server boundaries you can't run the package under the local admin account.
September 2, 2004 at 8:36 am
Yep Ron, that was the problem.
Thanks for your help.
Jay.
September 2, 2004 at 11:33 am
You're welcome.
Viewing 5 posts - 1 through 4 (of 4 total)
You must be logged in to reply to this topic. Login to reply