ASP Move File Problem

Author Message
agantony

  • Total Posts : 15
  • Scores: 0
  • Reward points : 0
  • Joined: 3/23/2007
  • Status: offline
ASP Move File Problem Friday, March 30, 2007 9:08 PM (permalink)
0
Hi All,
 
I am trying to move a file using the following code in my asp page. The error I am getting in IE when I run the sub is "object expected" . The path to the following files is on the server and I have full accessrights to the sever. I can't see where am I going wrong? (PS: New to Programming)
 
Many Thanks!
 
<%
Sub smove()
Dim ID, strInput, strOutput, filesys
ID = "09-123-4"
ID = ID&".txt"
strInput = "d:\tmpdir\"&ID
strOutput = "d:\results\"&ID
Set filesys = CreateObject("Scripting.FileSystemObject")
filesys.MoveFile strInput,strOutput
Set filesys = Nothing
End Sub
%>
<form>
<input type="button" name="move" value="MoveFile" onclick=smove()>
</form>
 
 
#1

    Online Bookmarks Sharing: Share/Bookmark

    Jump to:

    Current active users

    There are 0 members and 1 guests.

    Icon Legend and Permission

    • New Messages
    • No New Messages
    • Hot Topic w/ New Messages
    • Hot Topic w/o New Messages
    • Locked w/ New Messages
    • Locked w/o New Messages
    • Read Message
    • Post New Thread
    • Reply to message
    • Post New Poll
    • Submit Vote
    • Post reward post
    • Delete my own posts
    • Delete my own threads
    • Rate post

    2000-2012 ASPPlayground.NET Forum Version 3.9