Wrox Programmer Forums

Need to download code?

View our list of code downloads.

Go Back   Wrox Programmer Forums > Microsoft Office > Access and Access VBA > Access VBA
Password Reminder
Register
| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read
Access VBA Discuss using VBA for Access programming.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Access VBA section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developers’ questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
DRM-free e-books 300x50
Closed Thread
 
Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old December 29th, 2003, 10:01 PM
Authorized User
Points: 306, Level: 6
Points: 306, Level: 6 Points: 306, Level: 6 Points: 306, Level: 6
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Jun 2003
Location: , , .
Posts: 54
Thanks: 2
Thanked 0 Times in 0 Posts
Default Finding "Broken Queries" , etc.

Being on a restricted budget, I don't have the luxury of using tools like "Speed Ferret" and others. Often, I find myself in the position of having to change Field Names in tables, which breaks queries, forms, reports, macros, and vba code. While it would be wonderful to be able to cross-reference a field name and get a list of all the things I am going to break [u]in advance</u>, right now, I would settle for something that would just tell me which queries I have broken by changing a field name.

Would anyone have an idea how to do that in VBA?

I originally tried enumerating all queries and checking for a Field count of 0, but that was not conclusive. It did find some broken queries, but not a lot. Here is my code:


dim db as dao.database
dim qdf as dao.querydef
    set db = currentdb
    for each qdf in db.querydefs
        if qdf.fields.count = 0 then
            debug.print qdf.name
        end if
    next qdf



--- Tom
__________________
--- Tom
Closed Thread


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Broken CD ajb963 BOOK: Beginning Access VBA 19 October 28th, 2006 07:07 PM
Combining Queries or results from 2 queries Ford SQL Server 2000 24 November 7th, 2005 08:54 PM
broken cd waz84792 Flash (all versions) 5 October 22nd, 2004 08:42 AM
Broken References tcarnahan Access VBA 4 December 19th, 2003 12:10 AM
Broken Links kilika Forum and Wrox.com Feedback 1 September 15th, 2003 10:01 AM



All times are GMT -4. The time now is 10:55 PM.


Powered by vBulletin®
Copyright ©2000 - 2019, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.