First install http://www.quest.com/powershell/activeroles-server.aspx
Add-PSSnapin Quest.ActiveRoles.ADManagement -ErrorAction SilentlyContinue
$File = “C:\ita\securitygroups.txt”
$AllGroups = get-qadgroup -grouptype “Security” | select name, Description
$AllGroups | Foreach {
echo “”
echo “”
echo $_.name
echo $_.description
} | out-File $File