FileSystemObject problem

Results 1 to 2 of 2

Thread: FileSystemObject problem

  1. #1
    Join Date
    Dec 1969

    Default FileSystemObject problem

    Hi there<BR><BR>I posted yesterday about my IIS hanging when I execute the script to write a log file but after applying the correct security permissions for my folder it still hangs ;&#060; (oh but thanks for telling me how to set the security permissions coz that solved my db update problem). Anyway, here is the source code. Can anyone tell me what is wrong?<BR><BR>Many thanks!<BR><BR>&#039;Write user access log<BR>Const fsoForReading = 1<BR>Const fsoForWriting = 2<BR>Const fsoForAppending = 8<BR> <BR>Dim objFSO<BR>Dim objTextStream<BR> <BR>Set objFSO = Server.CreateObject("Scripting.FileSystemObject")< BR>If objFSO.FileExists("log.txt") Then<BR> Set objTextStream = objFSO.OpenTextFile("log.txt", fsoForAppending)<BR> objTextStream.WriteLine strLoginName & ", " & Now & "File found" <BR>Else<BR> Set objTextStream = objFSO.CreateTextFile("log.txt", fsoForWriting)<BR> objTextStream.WriteLine strLoginName & ", " & Now & "File created"<BR>End If <BR> <BR>objFSO.Close<BR>Set objFSO = Nothing<BR>Set objTextStream = Nothing<BR><BR>

  2. #2
    Join Date
    Dec 1969

    Default RE: FileSystemObject problem

    Have you got Norton AV running on the server?<BR><BR>There&#039;s an article in the FAQs on this problem, if so.<BR><BR>Craig.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts