locked
Diagnosing Cryptic Exception Message

    Question

  • I'm making a call to GetFlyoutPlacement in my WinRT application.  An exception is thrown with the super useful message.  A similar call to GetFlyoutPlacementTargetInfo gets me the same results:

    An exception of type 'System.Runtime.InteropServices.COMException' occurred in foo.exe but was not handled in user code

    Additional information: Error HRESULT E_FAIL has been returned from a call to a COM component.


    The exception has no inner exception, and no further information (that I could find) regarding the cause.

    Inspecting the variables doesn't reveal any obvious problems with the arguments, such as the controlSize being larger than the containerRect. 

    How else can I diagnose this exception?


    • Edited by bdares Tuesday, January 13, 2015 1:40 AM
    Tuesday, January 13, 2015 1:31 AM

All replies

  • Does the problem reproduce on other machines?

    Matt Small - Microsoft Escalation Engineer - Forum Moderator
    If my reply answers your question, please mark this post as answered.

    NOTE: If I ask for code, please provide something that I can drop directly into a project and run (including XAML), or an actual application project. I'm trying to help a lot of people, so I don't have time to figure out weird snippets with undefined objects and unknown namespaces.

    Tuesday, January 13, 2015 2:22 PM
    Moderator
  • I've reproduced it on another dev's machine.  
    Tuesday, January 13, 2015 6:55 PM
  • Can you share the code with us to reproduce it?

    Matt Small - Microsoft Escalation Engineer - Forum Moderator
    If my reply answers your question, please mark this post as answered.

    NOTE: If I ask for code, please provide something that I can drop directly into a project and run (including XAML), or an actual application project. I'm trying to help a lot of people, so I don't have time to figure out weird snippets with undefined objects and unknown namespaces.

    Tuesday, January 13, 2015 7:36 PM
    Moderator