Bueno, ahora estoy un poco dormido aún, pero te pego un código que tengo yo, para:
1º) Listar todas las carpetas que hay
2º) Al pinchar sobre cada nombre, se abre en una pag. asp las imagenes que hay
El código es esto:
Código:
Select Case Request.QueryString("acc")
Case "VerIn"
Set objFSO = CreateObject("Scripting.FileSystemObject")
Set objFolder = objFSO.GetFolder(Server.MapPath("za/avas/"& txtPath))
For Each objSubFolder In objFolder.SubFolders
txtFolder = replace(replace(objSubFolder, objFolder, ""), "_", " ")
intLen = len(txtFolder) - 1
txtFolder = right(txtFolder, intLen)
txtUrl = "avatares.asp?acc=VerAv&in="&txtPath&"&sub="&right(replace(objSubFolder, objFolder, ""), intLen)
response.write "<table width=""100%""><tr><td align=""left""> " & _
"<img src=""archivos/menu/navegar.gif""> <font class=""CABECERA"">"&txtFolder&"</font> " & _
" <a href="&txtURL&">[ Ver Avatares ]</a>" & _
"</td></tr></table>"
Next
Set objFSO = Nothing
Set objFolder = Nothing
Set objSubFolder = Nothing
Case "VerAv"
response.write "<table width=""100%"" align=center><tr>"
Set objFSO = CreateObject("Scripting.FileSystemObject")
Set objFolder = objFSO.GetFolder(Server.MapPath("za/avas/"&txtPath&"/"&txtSubPath))
j = 1
For Each objAva In objFolder.Files
pathAva = "za/avas/"&txtPath&"/"&txtSubPath&replace(replace(objAva, objFolder, ""), "\", "/")
response.write "<td width=100 vAlign=center align=middle>"
response.write "<img src="&pathAva&">"
response.write "</td>"
If j Mod 3 = 0 Then response.write "</tr><tr>"
j = j + 1
Next
response.write "</tr></table>"
Set objFolder = Nothing
Set objFSO = Nothing
End Select
Creo que buscas algo similar a esto ¿no? Pruebalo a ver que tal
P.D: Las carpetas tienen que tener la forma: Nombre_De_La_Carpeta (cambias " " por "_")