Код:
#include <File.au3>
#include <Array.au3>
Global Const $CAB = "cab"
Global Const $MSU = "msu"
Global $aFile[1]
$FileList = _FileListToArray(@ScriptDir)
If (Not IsArray($FileList)) And (@Error = 1) Then Exit
For $i = 1 To $FileList[0]
Switch StringRight($FileList[$i], 3)
Case $CAB
_ArrayAdd($aFile, StringRegExpReplace($FileList[$i], "^.*\\", ""))
Case $MSU
_ArrayAdd($aFile, StringRegExpReplace($FileList[$i], "^.*\\", ""))
EndSwitch
Next
If UBound($aFile, 1) = 1 Then
MsgBox(0, Default, "Нет файлов!")
Exit
Else
_ArrayDisplay($aFile,"$FileList")
EndIf