Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 210397
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 11, 20262026-05-11T18:00:05+00:00 2026-05-11T18:00:05+00:00

Ok, it’s been a while since I’ve worked with classic asp so I’m a

  • 0

Ok, it’s been a while since I’ve worked with classic asp so I’m a bit rusty. Here’s my question.

I’m trying to write a file to the file system using FSO. The code below is very simple. However, the file is not appearing and no errors are appearing. I know it’s running the code because I can add response.writes before and after this snippet and they both appear in the output. However, no file is created, no error is thrown. I’ve even changed it so it’s a bogus path to force an error. No dice. I added everyone to have read and write on the directory permissions. Still the same.

Ideas?

Here’s my code:

Dim objFSO
Set objFSO = Server.CreateObject("Scripting.FileSystemObject")

'Open the text file
Dim objTextStream
Set objTextStream = objFSO.OpenTextFile("d:\test.txt", True)

'Display the contents of the text file
objTextStream.WriteLine "howdy"

'Close the file and clean up
objTextStream.Close
Set objTextStream = Nothing
Set objFSO = Nothing
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-11T18:00:06+00:00Added an answer on May 11, 2026 at 6:00 pm

    Try this:

    <%
    
    if Append = true then
       iMode = 8
    else 
       iMode = 2
    end if
    set oFs = server.createobject("Scripting.FileSystemObject")
    set oTextFile = oFs.OpenTextFile("C:\wwwroot\Test.txt", iMode, True)
    oTextFile.Write "Test Content"
    oTextFile.Close
    set oTextFile = nothing
    set oFS = nothing
    
    %>
    

    I tried this locally, after setting the permissions on my directory and it worked.

    You can get the original source from here:
    http://www.freevbcode.com/ShowCode.Asp?ID=89

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Ask A Question

Stats

  • Questions 186k
  • Answers 186k
  • Best Answers 0
  • User 1
  • Popular
  • Answers
  • Editorial Team

    How to approach applying for a job at a company ...

    • 7 Answers
  • Editorial Team

    What is a programmer’s life like?

    • 5 Answers
  • Editorial Team

    How to handle personal stress caused by utterly incompetent and ...

    • 5 Answers
  • Editorial Team
    Editorial Team added an answer ENOSPC from msgget indicates that the system-wide maximum number of… May 12, 2026 at 5:14 pm
  • Editorial Team
    Editorial Team added an answer apt-get install manpages-dev May 12, 2026 at 5:14 pm
  • Editorial Team
    Editorial Team added an answer you should set the session parameter NLS_TIMESTAMP_FORMAT or NLS_TIMESTAMP_TZ_FORMAT to… May 12, 2026 at 5:14 pm

Related Questions

Ok so I thought it was fixed, but I'm getting totally inconsistent results. I
OK I'm redoing this since I messed it up. :) here's the xaml. <Window
Ok, it's been a while since I've worked with classic asp so I'm a
Ok strange behavior when it should work: The problem is if I don't declare
Ok, so it's almost as easy as pie already. But it really should be

Trending Tags

analytics british company computer developers django employee employer english facebook french google interview javascript language life php programmer programs salary

Top Members

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.