Wrox Programmer Forums
|
Classic ASP Professional For advanced coder questions in ASP 3. NOT for ASP.NET 1.0, 1.1, or 2.0.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Classic ASP Professional section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old April 13th, 2007, 07:11 AM
Authorized User
 
Join Date: Jan 2007
Posts: 35
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via MSN to saurabhj Send a message via Yahoo to saurabhj
Default ASP Upload Error

Hello Everyone,

I have a problem with my ASP Upload Script.

I am getting the error says
Quote:
quote:Invalid Procedure Call Or Argument
Code:
Set MyFileObject = Server.CreateObject("Scripting.FileSystemObject")
Set objFile = MyFileObject.CreateTextFile(filename,,-1)
For i = 1 to LenB(value)
   objFile.Write chr(AscB(MidB(value,i,1)))  'Error On This Line
Next
objFile.Close
Set objFile = Nothing
Can anybody here aware of this?

Any Help would be greatly appreciated.....

Thanks in Advanced......

-Saurabh
__________________
-Saurabh
 
Old May 5th, 2007, 12:53 AM
Authorized User
 
Join Date: May 2007
Posts: 10
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Hi,

Put the below code in the action page and find out the value of Session.CodePage

response.write "Session.CodePage=" & Session.CodePage
response.end


if result is: Session.CodePage=65001, do write the below code at the top of your action page...

If Session.CodePage = 65001 then
    Session.CodePage = 1252
end if


Or [u]just set the Session.CodePage to 1252</u>, that it :)

Akash - The Sky






Similar Threads
Thread Thread Starter Forum Replies Last Post
File upload error balesh.mind ASP.NET 2.0 Professional 2 August 20th, 2007 02:52 PM
ASP Upload nabeeljohn Classic ASP Professional 1 November 28th, 2005 05:59 AM
error in upload function blur_ivy .NET Web Services 0 February 26th, 2005 11:37 AM
file upload error Ashleek007 Beginning PHP 2 June 8th, 2004 05:44 PM
Upload Error Message isai Classic ASP Basics 0 September 10th, 2003 10:24 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.