The type initializer for 'PowerPresent.RibbonProcedures' threw an exception.error. RRS feed

  • Question

  • Hi all,

    I'm developing an addin for PowerPoint 2010, I have customized the ribbon using xml and in my ribbon.vb class I have a call back to handle ribbon button clicks.

    PublicSubRibbonButtonOnAction(ByValcontrol AsOffice.IRibbonControl)

    Public sub RibbonButtonOnAction (ByVal control As Office.IRibbonControl)

    Select case control.Id

    case "xrA"

    dim frm as Form=New Myform


    case "xrB"

    call mySub()

    End Select

    End sub

    When I click on button xrB which is the first case in my call back it works fine and displays the form, but when I click on the button xrB (second case ) I get following error on Call mySub() line

    The type initializer for 'PowerPresent.RibbonProcedures' threw an exception.

    problem is not from mySub() procedure it seems I can't call any procedure from there, but I can display forms

    I don't know what I'm missing here.


    • Edited by EdwardMM Friday, October 17, 2014 2:19 AM
    Friday, October 17, 2014 2:10 AM

All replies

  • Hello Edward,

    > call mySub()

    Where is the code of the sub?

    Did you try to debug the code? What line of code exactly throws the exception?

    Friday, October 17, 2014 10:41 AM