Results 1 to 2 of 2

Thread: VBscript file access

  1. #1

    Thread Starter
    New Member
    Join Date
    Aug 2000
    Posts
    1
    I am having trouble accessing a file through the filesystem object. It says server can not create object. If i log in as Administrator it runs perferctly so i feel it is a permissions problem but i am not sure as to which dll(s) to check the permissions on. Any help would be appreciated. it is is crashing on an OpenTextFile.
    thanks
    Jeremy

  2. #2
    Addicted Member Mage33's Avatar
    Join Date
    Aug 2000
    Location
    Petaluma, California
    Posts
    138

    Unhappy FSO

    The file system object seems a bit buggy to me, however I recently used it with success in this way:

    Set FSO = CreateObject("Scripting.FileSystemObject") 'Create it
    Set vFolder = fso.GetFolder ("whatever") 'this grabs whatever folder you want.
    Set Files = vFolder.files 'this sets vFolder.files to a list of every single file in the folder
    Set TestFilePath = FSO.CreateFolder("whatever")'this creates a new folder

    Hope this helps some, essentially that's the way you use the FSO. Also, microsoft.com has a very nice tutorial on it which can be found at http://msdn.microsoft.com/scripting/default.htm Click on VBScript, then go to tutorials and it will list an FSO Tutorial.
    Stephen Haney- 115 116 101 118 101 31 72 65 78 69 89
    -ShardsOfSilence.net- ^ My name in ASCII ^
    You forget something new every day
    | WinME | VB6 Pro | MSC++ | Lambda MOO |

Posting Permissions

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



Click Here to Expand Forum to Full Width