storbytossen> Jeg postede jo en løsning til dig tidligere, godt nok fordelt over to svar/kommentarer. Her får du en samlet HTML-fil - se om du ikke kan bruge det til noget:
<HTML>
<HEAD>
<TITLE>Billede Viser ver. 1.0</TITLE>
</HEAD>
<BODY>
<SCRIPT LANGUAGE="VBScript">
Function URLDecode(ByVal What)
'URL decode Function
'2001 Antonin Foller, PSTRUH Software,
http://www.pstruh.cz Dim Pos, pPos
'replace + To Space
What = Replace(What, "+", " ")
on error resume Next
Dim Stream: Set Stream = CreateObject("ADODB.Stream")
If err = 0 Then 'URLDecode using ADODB.Stream, If possible
on error goto 0
Stream.Type = 2 'String
Stream.Open
'replace all %XX To character
Pos = InStr(1, What, "%")
pPos = 1
Do While Pos > 0
Stream.WriteText Mid(What, pPos, Pos - pPos) + _
Chr(CLng("&H" & Mid(What, Pos + 1, 2)))
pPos = Pos + 3
Pos = InStr(pPos, What, "%")
Loop
Stream.WriteText Mid(What, pPos)
'Read the text stream
Stream.Position = 0
URLDecode = Stream.ReadText
'Free resources
Stream.Close
Else 'URL decode using string concentation
on error goto 0
'UfUf, this is a little slow method.
'Do Not use it For data length over 100k
Pos = InStr(1, What, "%")
Do While Pos>0
What = Left(What, Pos-1) + _
Chr(Clng("&H" & Mid(What, Pos+1, 2))) + _
Mid(What, Pos+3)
Pos = InStr(Pos+1, What, "%")
Loop
URLDecode = What
End If
End Function
Dim FilSystem, Mappe, Fil
Set FilSystem=CreateObject("Scripting.FileSystemObject")
sPath = URLDecode(window.location.href)
sPath = Left(sPath, InStrRev(sPath, "/")-1)
If LCase(Left(sPath, 8)) = "
file:///" Then
sPath = Right(sPath, Len(sPath)-8)
End If
MsgBox "HTML-filen ligger i: '" & sPath & "'" & vbCRLF & vbCRLF & "Tryk OK for at vise filerne i mappen..."
Set Mappe=FilSystem.GetFolder(sPath)
Set filer = Mappe.Files
For Each file in filer
sMsg = sMsg & file.Name & "<br>"
Next
document.Write(sMsg)
</SCRIPT>
</BODY>
</HTML>