?
Solved

DTS / UNC / Scripting.FileSystemObject

Posted on 2002-04-09
10
Medium Priority
?
943 Views
Last Modified: 2013-11-30
I am trying to access files using some vbscript in a DTS. However it fails by saying path not found on the
fso.getfolder(sFolder) line.


'**********************************************************************
'  Visual Basic ActiveX Script
'************************************************************************

Function Main()
     strFile = "\\unc_path\sharename"
          Set fso = CreateObject("Scripting.FileSystemObject")
     Set f = fso.GetFolder(sFolder)

etc..
0
Comment
Question by:gotaquestion
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 6
  • 3
10 Comments
 
LVL 2

Expert Comment

by:JamesT
ID: 6929687
Should you use strFile in the fso.GetFolder?

strFile = "\\unc_path\sharename"
Set fso = CreateObject("Scripting.FileSystemObject")
Set f = fso.GetFolder(strFile)
0
 
LVL 143

Expert Comment

by:Guy Hengel [angelIII / a3]
ID: 6930554
I agree with JamesT (points to him)!

CHeers
0
 
LVL 1

Author Comment

by:gotaquestion
ID: 6931573
that was a typo.
I had strfile in there.
but it still doesn't work.
0
What Is Blockchain Technology?

Blockchain is a technology that underpins the success of Bitcoin and other digital currencies, but it has uses far beyond finance. Learn how blockchain works and why it is proving disruptive to other areas of IT.

 
LVL 2

Accepted Solution

by:
JamesT earned 300 total points
ID: 6931596
I am sure this is obvious but make sure that the database can see that path and that permissions are not preventing access.
0
 
LVL 1

Author Comment

by:gotaquestion
ID: 6931632
I think it is a permissions problem, I just found a kb article on it.

http://support.microsoft.com/support/kb/articles/q197/9/64.asp?LNG=ENG&SA=PER

0
 
LVL 1

Author Comment

by:gotaquestion
ID: 6931708
I can't figure it out.  I've got the sql user account, and the iusr account both duplicated on the remote machine but I still get "path not found."  I can log on to the sql server with the sql account and map the drive no problem and doesn't ask for username password so I know the share exist.

Is there another account the DTS manager is using to connect to the remote server that I'm overlooking?

I've tried both the IP address and the computer.

Also, they are all win2k servers but with no domain just assigned to the same workgroup


0
 
LVL 2

Expert Comment

by:JamesT
ID: 6931742
This is from books online. It talks about debugging ActiveX scripts. If you have the required applications installed you can debug it and perhaps it will she some light.

Debugging ActiveX Scripts
If you have Microsoft® Windows® 2000, Microsoft Visual InterDev® 6.0 or the Microsoft Windows NT® 4.0 Option Pack installed, you can use the script debugger supplied with those products to troubleshoot your Microsoft ActiveX® scripts. Three types of events cause errors:

A forced break in the script execution.

Incorrect script syntax or object.

Objects that contain incorrect references.
Your ability to debug these errors depends on whether or not you have selected the Turn on just-in-time debugging check box.

How to select the Turn on just-in-time debugging option (Enterprise Manager)
To select the Turn on just-in-time debugging option

In the SQL Server Enterprise Manager console tree, right-click the Data Transformation Services node, and then click Properties.

Select the Turn on just-in-time debugging check box.

Important  If you select the Turn on just-in-time debugging check box, save your script or Data Transformation Services (DTS) package prior to running it or you will lose your changes. When you close the debugger window, the script and the launching application are also closed.
0
 
LVL 1

Author Comment

by:gotaquestion
ID: 6931778
thanks for the help james,
it was the sqlserveragent service.  I didn't know that that had an account too. I just thought you needed to worry about the sql server account. so once I put the sqlserveragent account on the remote machine it worked fine.

0
 
LVL 1

Author Comment

by:gotaquestion
ID: 6931787
thanks for the help james,
it was the sqlserveragent service.  I didn't know that that had an account too. I just thought you needed to worry about the sql server account. so once I put the sqlserveragent account on the remote machine it worked fine.

0
 
LVL 1

Author Comment

by:gotaquestion
ID: 6931853
thanks for the help james,
it was the sqlserveragent service.  I didn't know that that had an account too. I just thought you needed to worry about the sql server account. so once I put the sqlserveragent account on the remote machine it worked fine.

0

Featured Post

NEW Veeam Agent for Microsoft Windows

Backup and recover physical and cloud-based servers and workstations, as well as endpoint devices that belong to remote users. Avoid downtime and data loss quickly and easily for Windows-based physical or public cloud-based workloads!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Ever needed a SQL 2008 Database replicated/mirrored/log shipped on another server but you can't take the downtime inflicted by initial snapshot or disconnect while T-logs are restored or mirror applied? You can use SQL Server Initialize from Backup…
For both online and offline retail, the cross-channel business is the most recent pattern in the B2C trade space.
Familiarize people with the process of utilizing SQL Server functions from within Microsoft Access. Microsoft Access is a very powerful client/server development tool. One of the SQL Server objects that you can interact with from within Microsoft Ac…
Via a live example, show how to shrink a transaction log file down to a reasonable size.
Suggested Courses

752 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question