I am thinking that you want to loop throught the software and gather the data and then write the data after the loop ends. This yields one line in stead of writing after every key (Multiple lines).
Code quickly edited and not tested.
code:
$Index = 0
$Key = EnumKey($RootKey, $Index)
While @Error = 0
$RC = EnumValue($RootKey + $Key, 1)
If @Error = 0
$Value = ReadValue($RootKey + $Key, "DisplayName")
If $Value = ""
$Value = ReadValue($RootKey + $Key, "QuietDisplayName")
If $Value = ""
$Value = $Key
EndIf
EndIf
$Value2 = "" + Value2 + "," + $Value
EndIf
$Index = $Index + 1
$Key = EnumKey($RootKey, $Index)
Loop
$Value = substr($Value2 ,2)
$RC = WriteProfileString("$WSInfoFile", "ProgramInfo", "Software", "$Value")
Return
[ 03. September 2002, 16:25: Message edited by: Howard Bullock ]