Generating a List of Saved Views : View « Access « VBA / Excel / Access / Word






Generating a List of Saved Views

 
' set up a reference to the
' Microsoft ADO Ext. 2.7 for DDL and Security

Sub List_Views()
    Dim cat As New ADOX.Catalog
    Dim myView As ADOX.View
    cat.ActiveConnection = CurrentProject.Connection
    For Each myView In cat.Views
        Debug.Print myView.Name
    Next myView
End Sub

 








Related examples in the same category

1.Create view
2.Creating a View Based on a Table with SQL command
3.Deleting a View with SQL command
4.Execute the view