VBcoders Guest



Don't have an account yet? Register
 


Forgot Password?



Finding Broken references of your VBA Project through Code. This code reveals the Reference Name,Br

by Upendra Agnihotram (2 Submissions)
Category: Miscellaneous
Compatability: VB 6.0
Difficulty: Unknown Difficulty
Originally Published: Mon 13th September 2004
Date Added: Mon 8th February 2021
Rating: (1 Votes)

Finding Broken references of your VBA Project through Code. This code reveals the Reference Name,Broken status,Physical Path of Reference,is

Rate Finding Broken references of your VBA Project through Code. This code reveals the Reference Name,Br



Dim i As Integer
    
    For i = 1 To Application.References.Count
    
        'Get Reference Name, Broken status
        Debug.Print i & "." & Application.References(i).Name & "---" & Application.References(i).IsBroken
        'Warn User if a Broken Reference is in the application
            If Application.References(i).IsBroken = True Then
                MsgBox Application.References(i).Name & "is not loaded properly", vbCritical
                Exit Function
            End If
        'Get Full Path of Reference
        Debug.Print i & "." & Application.References(i).FullPath
        'Is the reference Built In
        Debug.Print i & "." & Application.References(i).BuiltIn
        'Get the Reference GUID
        Debug.Print i & "." & Application.References(i).Guid
        'Get the Reference Major version & Minor Version
        Debug.Print i & "." & Application.References(i).Major & "." & Application.References(i).Minor
        
    Next

End Function

Download this snippet    Add to My Saved Code

Finding Broken references of your VBA Project through Code. This code reveals the Reference Name,Br Comments

No comments have been posted about Finding Broken references of your VBA Project through Code. This code reveals the Reference Name,Br. Why not be the first to post a comment about Finding Broken references of your VBA Project through Code. This code reveals the Reference Name,Br.

Post your comment

Subject:
Message:
0/1000 characters