Drew Wutka
DWUTKA at Marlow.com
Tue Mar 11 16:21:12 CDT 2008
The attached is a .txt doc with a modified version of that function I posted earlier. The debug.print lines are commented out, instead, the function creates two tables, one for table and recordcounts, and one for table/query fields. Same function, so you have the option of selecting tables, queries, or both, and the second optional argument, when set to true, will get you field information too. I'm only getting the basic field type, if you want more information, like if the fields are indexed, etc, it's just a matter of getting more data out of the items in the Fields collection. Another FYI, this code, when placed in a module, is going to work on the local database because of currentproject.connection. If you replace all 'currentproject.connection' with a different (but valid) ADODB connection object, it will do the same process for any database (Access, MySQL, Oracle, etc.) (The beauty of ADO) Drew -----Original Message----- From: accessd-bounces at databaseadvisors.com [mailto:accessd-bounces at databaseadvisors.com] On Behalf Of Mark A Matte Sent: Tuesday, March 11, 2008 2:27 PM To: Access Developers discussion and problem solving Subject: Re: [AccessD] Record Count for all tables PART 2 Drew, Worked like a charm!!!...But I guess I didn't ask enough detail...because I was thought I would get the same Documentor functionality like in A97...anyway... Is there a similar way to get field names and types? (Sorry for having to ask twice) Thanks, Mark A. Matte The information contained in this transmission is intended only for the person or entity to which it is addressed and may contain II-VI Proprietary and/or II-VI Business Sensitive material. If you are not the intended recipient, please contact the sender immediately and destroy the material in its entirety, whether electronic or hard copy. You are notified that any review, retransmission, copying, disclosure, dissemination, or other use of, or taking of any action in reliance upon this information by persons or entities other than the intended recipient is prohibited.