|
-
Nov 9th, 2003, 01:22 AM
#1
Thread Starter
Addicted Member
file transfer in vb.net to a web server
file copy to web server ??
I am using the file copy command to copy jpeg images to a web server with a web forms project. the line of code is
FileCopy("e:\irean\ireanweb\pics\testbig.jpeg", Server.MapPath(""))
at this stage im just trying to put it in the main directory on the server
I can open the database ok using the connection string as follows
Public dbcConnection As String = "Provider=Microsoft.Jet.OLEDB.4.0;data source=" & Server.Mappath("ireantest.mdb")
however when I try to run it is says
The target directory already exists
the lines of code are
Line 85: gnAgentID = nID
Line 86: Label4.Text = "<b class=no2>Access Granted - transferring you to the Members Page</b>"
Line 87: FileCopy("e:\irean\ireanweb\pics\testbig.jpeg", Server.MapPath(""))
Line 88:
Line 89: Response.Redirect("frmUpload.aspx") '("members.html")
line 87 is the one with the error
would appreciate if anyone can help
regards
bh
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|