Results 1 to 2 of 2
  1. #1
    Join Date
    Jun 2002

    Unhappy Unanswered: Getting Error while creating a file in VB dll and using in ASP

    Hello Gurus,
    I have a class and I have a function/method with 4 parameters. first 3 are input and the last one is output.
    I am creating a file at "C:\" based on the input parameters and writing the records to the file.
    I tested this class from a VB project and the file is created successfully.

    Now I created a DLL using the Class and I am using this DLL in an ASP. I pass 3 input parameters and one output parameter variable. What I get is an error ( which I did not get when the class was run in the VB project) like Path/File Access Error (Error75). Can any of you guys see why I am getting this error when I try to execute the DLL from ASP but works fine in VB project when used as a class??


    Dim fso
    Dim txtfile
    Dim ts
    Set fso = CreateObject("Scripting.FileSystemObject")
    Const forreading = 1, forwriting = 2, forappending = 3

    If fso.FileExists(cfilname) Then
    Kill cfilname
    End If

    fso.CreateTextFile cfilname

    Set txtfile = fso.GetFile(cfilname)
    Set ts = txtfile.OpenAsTextStream(forwriting, 0)
    strrec = '1212121'
    ts.WriteLine strrec
    strrec = '2323231'
    ts.WriteLine strrec

  2. #2
    Join Date
    Jan 2003
    Does The IIS account have permissions to this directory? In other words does the IWAM account have permissions?
    Last edited by pjames; 03-14-03 at 12:51.

Posting Permissions

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