Wrox Programmer Forums
Classic ASP Professional For advanced coder questions in ASP 3. 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 Professional section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
Old May 24th, 2006, 08:25 PM
Authorized User
Join Date: Jul 2005
Posts: 10
Thanks: 0
Thanked 0 Times in 0 Posts
Default paging folders

The code bellow will display a list of folders in a directory. Now lets say I have 20 folders or any number of folders, I want to display the first 5 folders, then display another 5 folders and so on just like the paging concept how is it done?.

<table cellpadding="3" cellspacing="0" border="0" width="420">
<td width="120"> </td>
<td width="300">

Set objFSO = Server.CreateObject("Scripting.FileSystemObject")

If objFSO.FolderExists(myFolderPath) Then
'The main picture folder exists
Set objPicturesFolder = objFSO.GetFolder(myFolderPath)
Set collPicturesFolders = objPicturesFolder.SubFolders
For Each indPicturesFolder in collPicturesFolders
indPicturesFolderSpaces = Replace(indPicturesFolder.Name,"_"," ")
<img src="icons/orangeball.gif" align="top">
<a href="thumb.asp?Folder=<%= indPicturesFolder.Name %>" class="links">
<%= indPicturesFolderSpaces %></A>


Set collPicturesFolders = Nothing

'The main picture folder does not exists
No Pictures could be found.
End If

Your help is kindly appreciated.

Old May 28th, 2006, 09:12 AM
Authorized User
Join Date: Jun 2003
Posts: 79
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via ICQ to erobb Send a message via Yahoo to erobb

Paging is a DB function. Why not just count the folders?


Similar Threads
Thread Thread Starter Forum Replies Last Post
DB recordset paging using ajax paging? kumiko Classic ASP Basics 0 May 26th, 2008 10:23 AM
how to add folders beetle_jaipur ASP.NET 2.0 Basics 1 May 29th, 2007 12:50 AM
Copy folders surendran PHP How-To 2 July 25th, 2006 10:36 PM
Secure Folders itHighway Classic ASP Basics 5 December 16th, 2004 05:12 PM
Which folders to USE groupmatch BOOK: ASP.NET Website Programming Problem-Design-Solution 5 October 7th, 2004 07:52 PM

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