none
MS Access 2010 "missing broken reference to the file 'msacal70.ocx' version 7.0

    Question

  • Installed Access 2010 on my new Windows 7 machine.

    Tried to get into the Access file that I need and I get the following error:

    "missing or broken reference to file 'msacal70.ocx version 7.0"

    How do I fix this?  I need to access this database.

     

    Monday, February 14, 2011 4:23 PM

Answers

  • From some other database, try running the following code as ListReferences "C:\Folder\File.mdb"

    Sub ListReferences(WhichDatabase As String)
    On Error GoTo EH

    Dim appAccess As Access.Application
    Dim ref As Object

        If Len(Dir(WhichDatabase)) = 0 Then
            MsgBox "Sorry, " & WhichDatabase & " doesn't seem to exist."
        Else
            Set appAccess = New Access.Application
            appAccess.OpenCurrentDatabase WhichDatabase
            For Each ref In appAccess.VBE.ActiveVBProject.References
                If ref.IsBroken = True Then
                    Debug.Print "Broken, GUID - " & ref.Guid
                Else
                    Debug.Print ref.Description & " - " & ref.Name & " - " & _
                        ref.Major & "." & ref.Minor & vbCrLf & _
                        "       Location - " & ref.FullPath
                End If
            Next ref
            appAccess.CloseCurrentDatabase
            Set appAccess = Nothing
        End If

    Cleanup:
        Exit Sub

    EH:
        MsgBox Err.Number & ": " & Err.Description
        Resume Cleanup

    End Sub

    What do you see in the Immediate Window when you run that?

    Worst case, create a new database and import everything from the faulty one into the new one.

     


    Doug Steele, Microsoft Access MVP
    http://www.AccessMVP.com/djsteele (no e-mails, please!)
    Co-author Access Solutions — Tips, Tricks, and Secrets from Microsoft Access MVPs (ISBN 978-0-470-59168-0)
    • Marked as answer by Bruce Song Tuesday, February 22, 2011 9:56 AM
    Wednesday, February 16, 2011 10:20 PM

All replies

  • mscal70.ocx is an old Calendar item.

    My advice would be to remove the reference to it and either use the built-in Access 2010 calendar, or change your application to use an alternate calendars. Jeff Conrad has a good list of possibilities at http://www.accessmvp.com/JConrad/accessjunkie/calendars.html

    To remove the reference, go into the VB Editor, select Tools | References from the menu, then uncheck the reference to the ocx file.


    Doug Steele, Microsoft Access MVP
    http://www.AccessMVP.com/djsteele (no e-mails, please!)
    Co-author Access Solutions — Tips, Tricks, and Secrets from Microsoft Access MVPs (ISBN 978-0-470-59168-0)
    Monday, February 14, 2011 4:30 PM
  • Doug,

    After I clicked the "OK" for the error message, it opens up VB.  When I go to Tools the Reference option is dimmed out.

     

    Dave

    Tuesday, February 15, 2011 12:59 PM
  • The implication is that you've got code running.

    Click on the Run menu, and choose Break.


    Doug Steele, Microsoft Access MVP
    http://www.AccessMVP.com/djsteele (no e-mails, please!)
    Co-author Access Solutions — Tips, Tricks, and Secrets from Microsoft Access MVPs (ISBN 978-0-470-59168-0)
    Tuesday, February 15, 2011 1:07 PM
  • February 16, 2011

    Doug,

    My production software utilizes an Access database to communicate between the software and the UPS and FedEx computers in shipping.  I think.

    When I went to Run menue, the Break option is also dimmed out.

     

    Thank you for all help and time.

    Dave

    Wednesday, February 16, 2011 9:56 PM
  • From some other database, try running the following code as ListReferences "C:\Folder\File.mdb"

    Sub ListReferences(WhichDatabase As String)
    On Error GoTo EH

    Dim appAccess As Access.Application
    Dim ref As Object

        If Len(Dir(WhichDatabase)) = 0 Then
            MsgBox "Sorry, " & WhichDatabase & " doesn't seem to exist."
        Else
            Set appAccess = New Access.Application
            appAccess.OpenCurrentDatabase WhichDatabase
            For Each ref In appAccess.VBE.ActiveVBProject.References
                If ref.IsBroken = True Then
                    Debug.Print "Broken, GUID - " & ref.Guid
                Else
                    Debug.Print ref.Description & " - " & ref.Name & " - " & _
                        ref.Major & "." & ref.Minor & vbCrLf & _
                        "       Location - " & ref.FullPath
                End If
            Next ref
            appAccess.CloseCurrentDatabase
            Set appAccess = Nothing
        End If

    Cleanup:
        Exit Sub

    EH:
        MsgBox Err.Number & ": " & Err.Description
        Resume Cleanup

    End Sub

    What do you see in the Immediate Window when you run that?

    Worst case, create a new database and import everything from the faulty one into the new one.

     


    Doug Steele, Microsoft Access MVP
    http://www.AccessMVP.com/djsteele (no e-mails, please!)
    Co-author Access Solutions — Tips, Tricks, and Secrets from Microsoft Access MVPs (ISBN 978-0-470-59168-0)
    • Marked as answer by Bruce Song Tuesday, February 22, 2011 9:56 AM
    Wednesday, February 16, 2011 10:20 PM