473,395 Members | 1,905 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,395 software developers and data experts.

OpenTextFile just hangs

XPSp1/IIS 5.1

What am I doing wrong? The following code just hangs in asp page at
OpenTextFile() - and inet service manager just hangs if I try to unload app
at
this point -

<script runat="server" language="VBScript" >
Function JobList
filename = "privdata/curjobs.txt"
mappedname = Server.MapPath(filename)
Set fso = Server.CreateObject("Scripting.FileSystemObject")
if not fso.FileExists(mappedname) then
JobList = "Please check again later."
else
Set f = fso.OpenTextFile(mappedname)
JobList = f.ReadAll()
Set f = Nothing
end if
Set fso = Nothing
end function
</script>

The mappedname does point to the correct absolute path location (a virtual
dir under "documents and settings").

--
Regards,

Jim Allison
jw*********@bellsouth.net
(de-mung by removing '.1')

Jul 19 '05 #1
2 1614
Most likely this.

http://www.aspfaq.com/show.asp?id=2180

Ray at work

"jwallison" <jw*******@nospam.net> wrote in message
news:19*******************@bignews1.bellsouth.net. ..

The following code just hangs in asp page at Set fso = Server.CreateObject("Scripting.FileSystemObject")

Jul 19 '05 #2
That did it.

thanks -

"Ray at <%=sLocation%> [MVP]" <myfirstname at lane34 dot com> wrote in
message news:e3*************@TK2MSFTNGP11.phx.gbl...
Most likely this.

http://www.aspfaq.com/show.asp?id=2180

Ray at work

"jwallison" <jw*******@nospam.net> wrote in message
news:19*******************@bignews1.bellsouth.net. ..

The following code just hangs in asp page at

Set fso = Server.CreateObject("Scripting.FileSystemObject")


Jul 19 '05 #3

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

Similar topics

6
by: JT | last post by:
i have a text file that is used as a logfile for easier debugging. i am using the OpenTextFile method to write to this file. this method exists inside a logging function that can be called from...
3
by: Fie Fie Niles | last post by:
In my ASP (IIS 5.1), when I use oFile.OpenTextFile to open a file, the code stucks. How can I fix this problem? Thanks. set oFile = CreateObject("Scripting.FileSystemObject") strServerFileName...
0
by: Simon K | last post by:
I'm trying to write a .txt file with OpenTextFile method. This is working alright, but since I'm using some danish characters and use Flash to read the txt file I need to save the file as UTF-8 or...
2
by: Serge Myrand | last post by:
Hi, I cannot use the OpenTextFile method, it's never return and I get no error message! Setting Response.Buffer=False, has no effect. No matter if I use it ForReading or ForWriting, it never...
0
by: Randy King | last post by:
Newbie here, so please bear with me. I have a module that just hangs. I have tracked it down to this line in the genMappings() module: DoCmd.OutputTo acQuery, "Mappings", acFormatXLS, _...
0
by: Vladislav Moltchanov | last post by:
In the following example code some thing is wrong: <<<<<<<<<< Sub OpenTextFileTest Const ForReading = 1, ForWriting = 2, ForAppending = 3 Dim fs, f Set fs =...
2
by: Pierre Rouleau | last post by:
Hi all, I have a consistent test case where os.popen3() hangs in Windows. The system hangs when retrieving the lines from the child process stdout. I know there were several reports related to...
2
by: ShieldsJared | last post by:
Hello all, So I recently found out about redirecting the Standard Output of a vbscript back to my C# app but I've found a problem. When I run a script that calls OpenTextFile, I do not receive...
1
by: itskaps | last post by:
Hi all, My following program code works fine on win 2K server but the same is not working on win2K3 server. It's showing error as page cannot be displayed. After debugging, I found that...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
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
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
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
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,...

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.