Solved

Missing or broken reference after converting database to XP 2003

Posted on 2004-10-04
11
2,168 Views
Last Modified: 2008-01-09
We have just had our machines upgraded to XP with Access 2003.  We have an Access 97 database that we have just converted but we are now getting the following error:

"Your Microsoft Office Access database or project contains a missing or broken reference to the file 'doa2535.tlb version 3.5"

When I OK this - VB opens saying "Compile error: Can't find project or library" with Dim dbs As Database highlighted.

I have checked References and the following is ticked:

Visual Basic for Applications
Microsoft Access 11.0 Object Library
OLE Automation
Microsoft DOA 3.6 Object Library       **** Not 3.5??
Microsoft ActiveX Data Objects 2.1 Library

How do we get around this???
0
Comment
Question by:LearningAccess
  • 4
  • 4
  • 3
11 Comments
 
LVL 16

Assisted Solution

by:ahmedbahgat
ahmedbahgat earned 125 total points
ID: 12224382
try to untick the last 2 then restart access, then retick them again, however, if not successfull, try to remove the last one if you are not using ADO, and try, you may also try removing the DAO and keeping only the ADO

cheers
0
 
LVL 44

Expert Comment

by:Arthur_Wood
ID: 12225535
why do you think you need DAO 3.5 instead of the newer version 3.6?  If the 3.6 reference marked as MISSING? DOA 3.6 should be the correct reference.

AW



0
 
LVL 44

Expert Comment

by:Arthur_Wood
ID: 12225543
by the way, if you decide to migrate to ADO, then lines such as this:

Dim dbs As Database

will NOT work, as ADO doies not have a Database Object - This code is DAO specific.

ADO works with the Connection object, not the Database Object.

AW
0
 

Author Comment

by:LearningAccess
ID: 12231812
The error is saying it can't find "file 'doa2535.tlb version 3.5"??  In the references it has "DOA 3.6 Object Library".

Located a related Microsoft KB article for Access 2002 though.  http://support.microsoft.com/default.aspx?scid=kb;en-us;313233.

It is saying to check a box Microsoft DOA 2.5/3.5 Compatibility Library - but 2003 doesn't have this - do you know what else it could be??

Thank you so much!!!
0
 
LVL 16

Expert Comment

by:ahmedbahgat
ID: 12233190
you still can use DAO 3.6 instead of the DAO2.5/3.5

cheers
0
How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

 

Author Comment

by:LearningAccess
ID: 12234952
I have tried the first comment - unticking Microsoft DOA 3.6 Object Library & Microsoft ActiveX Data Objects 2.1 Library.  No change.

Where do I go from here?? (Tell me if you need more points...very desperate...but only have 195 left).
0
 
LVL 16

Expert Comment

by:ahmedbahgat
ID: 12235502
can you try compacting and repairing the db then try to compile if compile pops an error please post where the code is highlighted

do not worry anout points mate

cheers
0
 
LVL 44

Expert Comment

by:Arthur_Wood
ID: 12237494
after you UNTICK the two references, click the OK button, then RE-OPEN the References dialog, and RE-SELECT both of the previously UN-Selected references, to re-select them.  If they are unselected, you will get the error message that you are seeing.

AW
0
 

Author Comment

by:LearningAccess
ID: 12243491
Sorry, that is what I had meant - I have unticked and reticked as suggested.

Also: Tried to compact and repair database but getting the same error "Your Microsoft Office Access database or project contains a missing or broken reference to the file 'doa2535.tlb version 3.5".

Code:

Private Sub FillOptions()
' Fill in the options for this switchboard page.

    ' The number of buttons on the form.
    Const conNumButtons = 8
   
    Dim dbs As Database
    Dim rst As Recordset
    Dim strSQL As String
    Dim intOption As Integer
   
    ' Set the focus to the first button on the form,
    ' and then hide all of the buttons on the form
    ' but the first.  You can't hide the field with the focus.
    Me![Option1].SetFocus
    For intOption = 2 To conNumButtons
        Me("Option" & intOption).Visible = False
        Me("OptionLabel" & intOption).Visible = False
    Next intOption
   
    ' Open the table of Switchboard Items, and find
    ' the first item for this Switchboard Page.
    Set dbs = CurrentDb()
    strSQL = "SELECT * FROM [Switchboard Items]"
    strSQL = strSQL & " WHERE [ItemNumber] > 0 AND [SwitchboardID]=" & Me![SwitchboardID]
    strSQL = strSQL & " ORDER BY [ItemNumber];"
    Set rst = dbs.OpenRecordset(strSQL)
   
    ' If there are no options for this Switchboard Page,
    ' display a message.  Otherwise, fill the page with the items.
    If (rst.EOF) Then
        Me![OptionLabel1].Caption = "There are no items for this switchboard page"
    Else
        While (Not (rst.EOF))
            Me("Option" & rst![ItemNumber]).Visible = True
            Me("OptionLabel" & rst![ItemNumber]).Visible = True
            Me("OptionLabel" & rst![ItemNumber]).Caption = rst![ItemText]
            rst.MoveNext
        Wend
    End If

    ' Close the recordset and the database.
    rst.Close
    dbs.Close

End Sub
0
 
LVL 44

Accepted Solution

by:
Arthur_Wood earned 125 total points
ID: 12245037
are you using a Data Control, on one of your forms?  It could be that you have an old data control, that still holds the reference to the older version of DAO?  Just a wild guess.

What version of Access are you using?

Try making this small change in the code you showed, above

from Dim rst As Recordset

to

Dim rst as DAO.Recordset

Again, just a hunch.

AW
0
 

Author Comment

by:LearningAccess
ID: 12284042
Thanks...I have created a new switchboard to get around issue.  Still very wierd cause another database with the same code is working fine.  Due to urgency I couldn't play around with it any longer.
0

Featured Post

What Security Threats Are You Missing?

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

Join & Write a Comment

Database tuning – How to start and what to tune. This question is frequently asked by many people, both online and offline. There is no hard and fast rule-of-thumb for performance tuning, however, before beginning the tuning process one should a…
Using SQL Scripts we can save all the SQL queries as files that we use very frequently on our database later point of time. This is one of the feature present under SQL Workshop in Oracle Application Express.
Video by: Steve
Using examples as well as descriptions, step through each of the common simple join types, explaining differences in syntax, differences in expected outputs and showing how the queries run along with the actual outputs based upon a simple set of dem…
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

705 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

15 Experts available now in Live!

Get 1:1 Help Now