alias ListSounds {
var %i = $findfile([color:green]"c:\directory of files"[/color],*.wav,0)
while (%i) {
hadd -m SoundList $nopath($findfile([color:green]"c:\directory of files"[/color],*.wav,%i))
dec %i
}
dialog -m Sounds Sounds
}
on *:DIALOG:Sounds:init:*: {
var %x = $hget(SoundList,0).item
while (%x) {
did -a Sounds 1 $hget(SoundList,%x).item $hget(SoundList,%x).data
dec %x
}
hfree SoundList
}
dialog Sounds {
title "Sounds"
size -1 -1 167 170
option dbu notheme
list 1, 4 4 159 149, vsbar size sort
button "Close", 2, 128 156 32 12, ok
}