G
Ken Snell (MVP) said:You can do this by using the CurrentProject.AllReports collection, which
contains all the reports in the database. You can iterate through the
items in that collection.
Or you can run a query on the MSysObjects table (value of Type field in
this table is -32764 for reports):
SELECT [Name] AS ReportName
FROM MSysObjects
WHERE [Type] = -32764;
News said:Thats really cool. What are some other Values for other object, such as
forms and queries?
Ken Snell (MVP) said:You can do this by using the CurrentProject.AllReports collection, which
contains all the reports in the database. You can iterate through the
items in that collection.
Or you can run a query on the MSysObjects table (value of Type field in
this table is -32764 for reports):
SELECT [Name] AS ReportName
FROM MSysObjects
WHERE [Type] = -32764;
Douglas J. Steele said:Forms as -32768, Macros are -32764, Modules are -32766.
Queries are 5.
Tables are one of 1, 4 or 6. 1 indicates that the table is in the same
database, 6 indicates that it's a "simple" linked table (either linked to
another Jet database, or to something like Excel, Text or dBase), while 4
indicates it's linked through ODBC.
--
Doug Steele, Microsoft Access MVP
(no private e-mails, please)
News said:Thats really cool. What are some other Values for other object, such as
forms and queries?
Ken Snell (MVP) said:You can do this by using the CurrentProject.AllReports collection, which
contains all the reports in the database. You can iterate through the
items in that collection.
Or you can run a query on the MSysObjects table (value of Type field in
this table is -32764 for reports):
SELECT [Name] AS ReportName
FROM MSysObjects
WHERE [Type] = -32764;
Douglas J. Steele said:Forms as -32768, Macros are -32764, Modules are -32766.
Queries are 5.
Tables are one of 1, 4 or 6. 1 indicates that the table is in the same
database, 6 indicates that it's a "simple" linked table (either linked to
another Jet database, or to something like Excel, Text or dBase), while 4
indicates it's linked through ODBC.
--
Doug Steele, Microsoft Access MVP
(no private e-mails, please)
News said:Thats really cool. What are some other Values for other object, such as
forms and queries?
Ken Snell (MVP) said:You can do this by using the CurrentProject.AllReports collection, which
contains all the reports in the database. You can iterate through the
items in that collection.
Or you can run a query on the MSysObjects table (value of Type field in
this table is -32764 for reports):
SELECT [Name] AS ReportName
FROM MSysObjects
WHERE [Type] = -32764;
Ken Snell (MVP) said:Douglas -
Typo? You have the same number for macros as for reports?
--
Ken Snell
<MS ACCESS MVP>
Douglas J. Steele said:Forms as -32768, Macros are -32764, Modules are -32766.
Queries are 5.
Tables are one of 1, 4 or 6. 1 indicates that the table is in the same
database, 6 indicates that it's a "simple" linked table (either linked to
another Jet database, or to something like Excel, Text or dBase), while 4
indicates it's linked through ODBC.
--
Doug Steele, Microsoft Access MVP
(no private e-mails, please)
News said:Thats really cool. What are some other Values for other object, such as
forms and queries?
You can do this by using the CurrentProject.AllReports collection,
which contains all the reports in the database. You can iterate through
the items in that collection.
Or you can run a query on the MSysObjects table (value of Type field in
this table is -32764 for reports):
SELECT [Name] AS ReportName
FROM MSysObjects
WHERE [Type] = -32764;
Ken Snell (MVP) said:Douglas -
Typo? You have the same number for macros as for reports?
--
Ken Snell
<MS ACCESS MVP>
Douglas J. Steele said:Forms as -32768, Macros are -32764, Modules are -32766.
Queries are 5.
Tables are one of 1, 4 or 6. 1 indicates that the table is in the same
database, 6 indicates that it's a "simple" linked table (either linked to
another Jet database, or to something like Excel, Text or dBase), while 4
indicates it's linked through ODBC.
--
Doug Steele, Microsoft Access MVP
(no private e-mails, please)
News said:Thats really cool. What are some other Values for other object, such as
forms and queries?
You can do this by using the CurrentProject.AllReports collection,
which contains all the reports in the database. You can iterate through
the items in that collection.
Or you can run a query on the MSysObjects table (value of Type field in
this table is -32764 for reports):
SELECT [Name] AS ReportName
FROM MSysObjects
WHERE [Type] = -32764;