Access系統表MsysObjects包含了數據庫對象列表,盡管未在文檔中記載,你仍可通過查詢它來獲取你想要的.
注:請不要有意或無意地修改任何Access系統表,否則會出現不可意料的情況.
使用下列SQL語句來獲取你想要的
查詢:
SELECTMSysObjects.NameFROMMsysObjectsWHERE(Left([Name],1)<>"~")AND(MSysObjects.Type)=5ORDERBYMSysObjects.Name;
窗體:
SELECTMSysObjects.NameFROMMsysObjectsWHERE(Left([Name],1)<>"~")AND(MSysObjects.Type)=-32768ORDERBYMSysObjects.Name;
表:
SELECTMSysObjects.NameFROMMsysObjectsWHERE(Left([Name],1)<>"~")AND(Left$([Name],4)<>"Msys")AND(MSysObjects.Type)=1ORDERBYMSysObjects.Name;
報表:
SELECTMSysObjects.NameFROMMsysObjectsWHERE(Left([Name],1)<>"~")AND(MSysObjects.Type)=-32764ORDERBYMSysObjects.Name;
模塊:
SELECTMSysObjects.NameFROMMsysObjectsWHERE(Left([Name],1)<>"~")AND(MSysObjects.Type)=-32761ORDERBYMSysObjects.Name;
宏:
SELECTMSysObjects.NameFROMMsysObjectsWHERE(Left([Name],1)<>"~")AND(MSysObjects.Type)=-32766ORDERBYMSysObjects.Name;