none
Invalid Procedure Call or Argument error comes RRS feed

  • Question

  • Hi,

    I have following code but in some cases I get Invalid Procedure Call or Argument error while executing following line of this method :CustomRibbon.Invalidate:

    Public Sub RefreshRibbon()
    On Error Resume Next
            If Not IsNothing(CustomRibbon) Then
                CustomRibbon.Invalidate
            End If
    End Sub

    Please help.

    Thanks,

    Rashid

    Friday, December 28, 2012 9:24 AM

Answers

  • Try:

    Public Sub RefreshRibbon()
    On Error Resume Next
    If Not CustomRibbon Is Nothing Then
      CustomRibbon.Invalidate
    End If
    End Sub

    Cheers
    Paul Edstein
    [MS MVP - Word]

    Friday, December 28, 2012 11:03 AM