Wrox Programmer Forums

Need to download code?

View our list of code downloads.

Go Back   Wrox Programmer Forums > ASP.NET and ASP > ASP 3 Classic ASP Active Server Pages 3.0 > Classic ASP Basics
Password Reminder
Register
| FAQ | Members List | Search | Today's Posts | Mark Forums Read
Classic ASP Basics For beginner programmers starting with "classic" ASP 3, pre-".NET." NOT for ASP.NET 1.0, 1.1, or 2.0
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Classic ASP Basics section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developers’ questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
DRM-free e-books 300x50
Reply
 
Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old December 22nd, 2003, 01:02 AM
Authorized User
 
Join Date: Jul 2003
Location: , , .
Posts: 46
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via ICQ to stalker Send a message via MSN to stalker
Default File System Object in Server Side

HI!

I have this function.. It always worked.. now it doesn't and I don't know why coz I don't think I changed anything in my server.. I already instaled WinXp Pro in a brand new PC and tested the site but the error still appears...

What happens is that I am trying to use ASP File System Object and if I try to use the method FileExists or any other ordinary method it woks fine.. But it I try to get the handle to a File or Folder with the GetFile or GetFolder methods the site getts lazzy and doesn't open! It never returns an error.. but stays there for a long time.. Until i give up! I don't think there's nothing wrong with the script.. It works fine in Client Side.. but in Server side.. maybe you can help me.. It halts in the GetFolder statement! Thx

function listfolders() {
    var styles = new Array();

<%
    Dim ObjFSO, StyleCounter
    Dim objFolder
    Set ObjFSO = Server.CreateObject("Scripting.FileSystemObject")
    Set objFolder = objFSO.GetFolder(Server.MapPath("..\style\")) ''here!!
    StyleCounter = 0

    For Each objStyle in objFolder.SubFolders
        Response.write "(blablabla)"
        StyleCounter = StyleCounter + 1
    Next
%>
    return styles;
}

Reply With Quote
  #2 (permalink)  
Old December 22nd, 2003, 06:39 AM
Imar's Avatar
Wrox Author
Points: 72,073, Level: 100
Points: 72,073, Level: 100 Points: 72,073, Level: 100 Points: 72,073, Level: 100
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Jun 2003
Location: Utrecht, Netherlands.
Posts: 17,089
Thanks: 80
Thanked 1,587 Times in 1,563 Posts
Default

Hi there,

Are you running programs like Norton Antivirus or McAfee Antivirus?
If so, check the options dialog for a feature called Script Blocking or something similar. This option blocks .vbs scripts and the FileSystemObject. If this seems to be the problem, it's up to you wether you want to sacrifice some security for the features of the FSO.

Cheers,

Imar

---------------------------------------
Imar Spaanjaars
Everyone is unique, except for me.
Reply With Quote
  #3 (permalink)  
Old December 22nd, 2003, 09:48 AM
Authorized User
 
Join Date: Jul 2003
Location: , , .
Posts: 46
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via ICQ to stalker Send a message via MSN to stalker
Default

AHAHAAH!!! thx man!!! I never figured out why it all stop working at the same time at all my 3 computers!! ahaahah now that you told me that I remember that I installed Norton at the same time in all the computers!!!

THX!! Will check it out!!

Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
File System Object question fogofogo Classic ASP Basics 1 December 8th, 2005 04:14 PM
File System Object kumar_rajeshk Pro VB 6 7 April 28th, 2004 01:35 AM
File System Object Permissions kilika Classic ASP Basics 2 August 6th, 2003 09:23 AM



All times are GMT -4. The time now is 03:59 PM.


Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.