473,493 Members | 2,254 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

Simple File Upload Script

I found this when searching. I need to have a simple script that will
upload a single file.
It is giving me an error on Set upl =
Server.CreateObject("ASPSimpleUpload.Upload")
It is saying :

Server object, ASP 0177 (0x800401F3)
Invalid class string

Am I missing something? A DLL perhaps?

----------------------------------------------------------------------------

Option Explicit

Dim upl, NewFileName

Set upl = Server.CreateObject("ASPSimpleUpload.Upload")

If Len(upl.Form("File1")) > 0 Then
NewFileName = "/Upload/" & upl.ExtractFileName(upl.Form("File1"))
If upl.SaveToWeb("File1", NewFileName) Then
Response.Write("File successfully written to disk.")
Else
Response.Write("There was an error saving the file to disk.")
End If
End If
%>

<html><head><title>ASP Simple Upload Example #1</title></head></title>
<body>
<form method="POST" action="test.Asp" enctype="multipart/form-data">
Select a file to upload: <input type="file" name="File1" size="30">
<input type="submit" name="submit" value="Upload Now">
</form>
</body>
</html>
Jul 22 '05 #1
2 7448
Yes, you are missing the ASP Simple UPload component. You must get that
(purchase it? Maybe it's free? Not sure) and install it on the server
before you can use it.

Okay, as it turns out, this is the component from a company that's gone.
You'll have to go with a different component that still exists. You can
find some upload options here: http://www.aspfaq.com/show.asp?id=2189

Ray at work
"SU_Oran" <dt*******@hotmail.com> wrote in message
news:e8**************@TK2MSFTNGP15.phx.gbl...
I found this when searching. I need to have a simple script that will
upload a single file.
It is giving me an error on Set upl =
Server.CreateObject("ASPSimpleUpload.Upload")
It is saying :

Server object, ASP 0177 (0x800401F3)
Invalid class string

Am I missing something? A DLL perhaps?

-------------------------------------------------------------------------- --
Option Explicit

Dim upl, NewFileName

Set upl = Server.CreateObject("ASPSimpleUpload.Upload")

If Len(upl.Form("File1")) > 0 Then
NewFileName = "/Upload/" & upl.ExtractFileName(upl.Form("File1"))
If upl.SaveToWeb("File1", NewFileName) Then
Response.Write("File successfully written to disk.")
Else
Response.Write("There was an error saving the file to disk.")
End If
End If
%>

<html><head><title>ASP Simple Upload Example #1</title></head></title>
<body>
<form method="POST" action="test.Asp" enctype="multipart/form-data">
Select a file to upload: <input type="file" name="File1" size="30">
<input type="submit" name="submit" value="Upload Now">
</form>
</body>
</html>

Jul 22 '05 #2
Thank you sir.
"Ray Costanzo [MVP]" <my first name at lane 34 dot commercial> wrote in
message news:uK**************@TK2MSFTNGP09.phx.gbl...
Yes, you are missing the ASP Simple UPload component. You must get that
(purchase it? Maybe it's free? Not sure) and install it on the server
before you can use it.

Okay, as it turns out, this is the component from a company that's gone.
You'll have to go with a different component that still exists. You can
find some upload options here: http://www.aspfaq.com/show.asp?id=2189

Ray at work
"SU_Oran" <dt*******@hotmail.com> wrote in message
news:e8**************@TK2MSFTNGP15.phx.gbl...
I found this when searching. I need to have a simple script that will
upload a single file.
It is giving me an error on Set upl =
Server.CreateObject("ASPSimpleUpload.Upload")
It is saying :

Server object, ASP 0177 (0x800401F3)
Invalid class string

Am I missing something? A DLL perhaps?


--------------------------------------------------------------------------
--

Option Explicit

Dim upl, NewFileName

Set upl = Server.CreateObject("ASPSimpleUpload.Upload")

If Len(upl.Form("File1")) > 0 Then
NewFileName = "/Upload/" & upl.ExtractFileName(upl.Form("File1"))
If upl.SaveToWeb("File1", NewFileName) Then
Response.Write("File successfully written to disk.")
Else
Response.Write("There was an error saving the file to disk.")
End If
End If
%>

<html><head><title>ASP Simple Upload Example #1</title></head></title>
<body>
<form method="POST" action="test.Asp" enctype="multipart/form-data">
Select a file to upload: <input type="file" name="File1" size="30">
<input type="submit" name="submit" value="Upload Now">
</form>
</body>
</html>


Jul 22 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
1784
by: Willoughby Bridge | last post by:
I am having trouble with a file upload script. Have tried a lot of different methods and the problem boils down to the $_FILES variable not being picked up. Below is a simple example of...
2
2144
by: Chuck | last post by:
Hi, can anyone provide or point me in the direction of a simple python file upload script? I've got the HTML form part going but simply putting the file in a directory on the server is what I'm...
3
1095
by: Fred Nelson | last post by:
Hi: I'm a newby and I am writing a VB.NET Web application where I would like to allow the users to upload a file from their computer to my web server. On the server I have already determined...
7
3165
by: pbd22 | last post by:
hi. i am having probs understanding how to grab a file being uploaded from a remote client. i am using hidden input fields for upload such as: <input id="my_file_element" type="file"...
1
1818
by: fatjoez | last post by:
Hey there. I've been trying to modify my file upload script so that it handles 10 files instead of one. i was thinking the most straightforward way would be to add a FOR LOOP? placed...
0
2300
by: wasif | last post by:
I am trying to upload file using ajax and php but having some problems. it always says that there was a problem and file is not uploaded. here is the code form and ajax code <!DOCTYPE html...
1
3926
by: kksandeep | last post by:
i am using this three files to uplod file. i got this file from net but i think these have some error. i am new to this field plz help the script i found is some helpful but not too that i need ...
24
7671
by: owz2008 | last post by:
This has probably been covered before but could not find a similar thread. Basically I have created a form which can be viewed at www.icomworks.co.uk/canvaspayform.html I want to submit the...
0
6989
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
7195
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
5453
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
1
4889
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
3088
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
3078
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
1400
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
1
644
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
285
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.