This is a multi-part message in MIME format.
Try using the SaveAs method instead of the Save method.
dim strBase, strPath, strName
blnVal =3D false
strBase =3D "d:\126.96.36.199\Store\images\productimages"
if Upl.Form("File1").TotalBytes <> 0 then
strName =3D Mid(Upl.UserFilename, InstrRev(Upl.UserFilename, "\") +
' change path1 to whatever you need
strPath =3D Server.MapPath(strBase & "\path1\")
On Error resume next
Upl.Form("File1").SaveAs strPath & strName
if Err =3D 0 then
blnVal =3D true
strName =3D "Error uploading the file: " & strName &". Err: " &
Err.Number &" - "&Err.Description
if Not blnVal then
' do it again... or better yet make the above code into a function so
you can reuse it
----- Original Message -----
From: "Daniel O'Dorisio" <dodorisio@h...>
To: "Code Clinic" <proasp_codeclinic@p...>
Sent: Sunday, April 08, 2001 4:10 AM
Subject: Sa File up
> i am trying to create a upload page for the back-end administration of
> ecommerce site. and what i have is 3 files (thumb image, reg image,
> large image) that i want to upload to different directories. the
> all the picture names are the productid num so it makes it easy to
> here is what i am doing right now
> Dim upl
> Set upl =3D Server.CreateObject("softArtisans.FileUp")
> upl.path =3D "d:\188.8.131.52\Store\images\productimages\thumbs"
> upl.path =3D "d:\184.108.40.206\Store\images\productimages\regular"
> upl.path =3D "d:\220.127.116.11\Store\images\productimages\large"
> set upl =3D nothing
> Response.Write "File Uploaded"
> but the prob is... it uploads all the images to the one directory
> and not to each dir. am i overestimating the abilities of sa-file up.
> checked the documentation, but havnt found anything so far.. i am
> looking though. i kinda want them to all be in one form as it will be
> prodict images for one product. also, i need to get the short filename
> of the whole thing (xxxxx.jpg instead of c:\my images\xxxxx.jpg) any
> on how that can be done. can it with the file field?