Server object, ASP 0177 Error posting data from form

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I have a form with various info and when the submit form button is pressed
the code in referral_process.asp is run:
<FORM action=referral_process.asp
method=post encType=multipart/form-data>

I am trying to upload the data (in PDF format) to an FTP site:
This is the referral_process.asp code:
Thank you for uploading your file.<br>
<% Set upl = Server.CreateObject("Referral.pdf") %>
<% upl.SaveAs "C:\temp\upload.out" %><BR>
Total Bytes Written: <%=upl.TotalBytes%>

it is failing on server.createObject("Referral.pdf") above. I don't have a
much experience instantiating objects and I was wondering if anyone could
give me some ideas on what to do here?

Thanks,
Phil
 
The problem is that Server.CreateObject() is expecting a ProgId as a
parameter. For instance, "ADODB.Recordset" is an example of a ProgId. It
looks like you are trying to invoke the name of a PDF file as a ProgId. A
ProgId usually has nothing to do with the name of the DLL it references.

Are you trying to use a file upload component to process the uploaded file?
If so, review the help documentation for that upload component. It should
include, amongst other things, the ProgId to use in code and installation
instructions for the DLL.
 
Back
Top