Print Page | Close Window

mySmartUpload: Error Invalid Files Name

Printed From: Web Wiz Forums
Category: General Discussion
Forum Name: Classic ASP Discussion
Forum Description: Discussion on Active Server Pages (Classic ASP).
URL: https://forums.webwiz.net/forum_posts.asp?TID=6583
Printed Date: 31 March 2026 at 3:07pm
Software Version: Web Wiz Forums 12.08 - https://www.webwizforums.com


Topic: mySmartUpload: Error Invalid Files Name
Posted By: Epon
Subject: mySmartUpload: Error Invalid Files Name
Date Posted: 20 October 2003 at 5:28am

Hi,

I am trying to use the mySmartUpload component to allow people to upload files into my server. However, I keep getting the error Invalid Files Name 'logopic' (Error 1205). Here is my code snippet:

In my first page I have a form with a file input type

<input type="file" name="logopic" size="65"> 

In my next page,

 On Error Resume Next

'  Variables
'  *********
   Dim mySmartUpload
   Dim intCount

'  Object creation
'  ***************
   Set mySmartUpload = Server.CreateObject("aspSmartUpload.SmartUpload")

'  Only allow txt or htm files
'  ***************************
   mySmartUpload.AllowedFilesList = "jpg,gif,bmp,png"

'  Upload
'  ******
   mySmartUpload.Upload

   intCount = mySmartUpload.Save("/MP")

strLogoPic = mySmartUpload.Files("logopic").FileName

If Err Then
      Response.Write(Err.description)
End if

I then get the error message Invalid Files Name 'logopic' (Error 1205). I already checked that the name of my input object in the previous page is indeed 'logopic' but I still get this error.

Can anybody help me? I have been stuck at this for some time.

Thanks.

Epon

 




Replies:
Posted By: God_Struth
Date Posted: 20 October 2003 at 11:31am
Shouldn't this section:

' Only allow txt or htm files
' ***************************
   mySmartUpload.AllowedFilesList = "jpg,gif,bmp,png"




Look Like This:

' Only allow txt or htm files
' ***************************
   mySmartUpload.AllowedFilesList = ".jpg,.gif,.bmp,.png"

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

Since its not recognising the extension, try that first.

-------------
"I'm only trying to help......"


Posted By: Epon
Date Posted: 20 October 2003 at 8:46pm

Hi,

Tried it. But didn't work. Anyway the

'  Only allow txt or htm files
'  ***************************
   mySmartUpload.AllowedFilesList = "jpg,gif,bmp,png"

is based on the sample code that was provided with the component when I downloaded it.

Any other suggestions or tips?

Thanks.




Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.08 - https://www.webwizforums.com
Copyright ©2001-2026 Web Wiz Ltd. - https://www.webwiz.net