Does anyone know how to limit the size of a member's file folder who has an uploaded file folder for images, files, etc? For example, if I want a file folder to only be 150K and allow only a total of that amount to be used. I want my members to be able to upload images into their own folder, but I don't want them to be able to put more than just so much in it.
you would just need to add some fso code to check for the folder size before you allowed uploading. So assuming you have an object called fldr which represents the users folder, just use fldr.Size to grab the size in bytes.
you would just need to add some fso code to check for the folder size before you allowed uploading. So assuming you have an object called fldr which represents the users folder, just use fldr.Size to grab the size in bytes.
Thank you Nikkol for the reply!
Would you mind helping me with this? I am using Huw's file upload for Snitz 3.3, and you know how scarce help for this MOD is .
There is a process for checking the image size and allowing/disallowing it before uploading to the server. Could I adapt this code for the fldr.Size you mentioned?
I'll look into the code and see what I come up with.
'''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''' ' GenerateFolderInformation ' Purpose: ' Generates a string describing the current state of a folder. ' Demonstrates the following ' - Folder.Path ' - Folder.Name ' - Folder.DateCreated ' - Folder.DateLastAccessed ' - Folder.DateLastModified ' - Folder.Size ''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
I also found two scripts ... one in VBScript and the other in JScript at: