This sample illustrates using SQL Distributed Management Objects (SQL-DMO) objects supplied with Microsoft® SQL Server™ 2000. This Microsoft® Visual Basic® sample demonstrates how to use the SQLServer enumeration methods.
It also shows a way to use recordset objects to show the values in a returned QueryResult.
C:\Program Files\Microsoft SQL Server\80\Tools\Devtools\Samples\Sqldmo\Vb\Enums