Sub ShowUserRosterMultipleUsers()
Dim cn As New ADODBConnection
Dim cn As New ADODBConnection
Dim rs As New ADODBRecordset
Dim i j As Long
cnProvider = "MicrosoftJetOLEDB"
cnOpen "Data Source=c:Northwindmdb"
cnOpen "Provider=MicrosoftJetOLEDB;" _
& "Data Source=c:Northwindmdb"
; The user roster is exposed as a providerspecific schema rowset
; in the Jet OLE DB provider You have to use a GUID to
; reference the schema as providerspecific schemas are not
; listed in ADO;s type library for schema rowsets
Set rs = cnOpenSchema(adSchemaProviderSpecific _
"{bbddbdbfcfb}")
;Output the list of all users in the current database
DebugPrint rsFields()Name "" rsFields()Name _
"" rsFields()Name rsFields()Name
While Not rsEOF
DebugPrint rsFields() rsFields() _
rsFields() rsFields()
rsMoveNext
Wend
End Sub