locked
DoubleTapped Event Crashes When Trying to Navigate To Different Page

    Question

  • Hello,

    I have the following code to handle an event for an item listed in GridView():

    sessions->DoubleTapped += ref new DoubleTappedEventHandler(this,&BlankPage::btnReview_DblClick);

     

    And the event handler is as follows:

    void BlankPage::btnReview_DblClick(Object^ sender, DoubleTappedRoutedEventArgs^ e)
    {
     TypeName pagetype = { ReviewPage::typeid->FullName, TypeKind::Metadata };
     this->Frame->Navigate(pagetype, nullptr);
    }

    When I run the code, and implement the double tap (double click on the mouse), the app locks up and eventually returns to original screen. The ReviewPage does not get loaded. I know the ReviewPage works as I am able to access it with a regular button Click event.

    Is this a bug or is there something I'm doing wrong?

    Thanks.

    Monday, June 18, 2012 3:59 AM

All replies

  • Hi Indesyne,

    If you run this in the debugger can you see where the app crashes and what the exception is? Are you also handling the Click event in a way that makes the DoubleTapped event invalid?

    --Rob

    Tuesday, June 19, 2012 1:56 AM
    Owner
  • Hi Rob,

    The double click event is taken from a GridView() list item. So when a user double clicks an item in GridView() it would go to the above code:

    auto sessions = ref new GridView();

    sessions->DoubleTapped += ref new DoubleTappedEventHandler(this,&BlankPage::btnReview_DblClick);

    void BlankPage::btnReview_DblClick(Object^ sender, DoubleTappedRoutedEventArgs^ e)
    {
     String^ paramString;
     TypeName pagetype = { ReviewPage::typeid->FullName, TypeKind::Metadata };
     this->Frame->Navigate(pagetype, paramString);
    }

     

    The Click event is taken from a Button element in XAML:

    <Button HorizontalAlignment="Left" Style="{StaticResource ReviewAppBarButtonStyle}" Click="btnReview_Click"/>

    void BlankPage::btnReview_Click(Object^ sender, RoutedEventArgs^ e)
    {
     String^ paramString;
     TypeName pagetype = { ReviewPage::typeid->FullName, TypeKind::Metadata };
     this->Frame->Navigate(pagetype, paramString);
    }

    The Click event works perfectly. The app is able to load the ReviewPage just fine.

    The double click on the other hand, does not. Even though the event handler codes for each respective events are exactly the same, the double click for some reason crashes.

    Thanks.



    • Edited by Indesyne Wednesday, June 20, 2012 4:53 AM
    Wednesday, June 20, 2012 4:51 AM
  • Did you notice the exception in the debugger output window? I'll see if I can recreate the problem on my end as well.

    David Lamb

    Wednesday, June 20, 2012 10:32 PM
    Moderator
  • Hi David,

    The exception messge:

    Unhandled exception at 0x6047978E (Windows.UI.Xaml.dll) in tkos2.exe: 0xC0000602:  A fail fast exception occurred. Exception handlers will not be invoked and the process will be terminated immediately.

    Thanks.

    Monday, June 25, 2012 1:40 PM
  • There's more to it:

    'tkos2.exe' (Win32): Loaded 'C:\Users\Indesyne\Documents\Visual Studio 11\Projects\tkos2\Release\tkos2\AppX\tkos2.exe'. Symbols loaded.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\ntdll.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\kernel32.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\KernelBase.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Program Files\WindowsApps\Microsoft.VCLibs.110_11.0.50202.1_x86__8wekyb3d8bbwe\vccorlib110.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\combase.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Program Files\WindowsApps\Microsoft.VCLibs.110_11.0.50202.1_x86__8wekyb3d8bbwe\msvcp110.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Program Files\WindowsApps\Microsoft.VCLibs.110_11.0.50202.1_x86__8wekyb3d8bbwe\msvcr110.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\ole32.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\shell32.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\oleaut32.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\msvcrt.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\rpcrt4.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\sechost.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\gdi32.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\user32.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\shlwapi.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\sspicli.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\cryptbase.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\imm32.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\msctf.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\bcryptprimitives.dll'. Cannot find or open the PDB file.

    The thread 0x1320 has exited with code 0 (0x0).

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\SHCore.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\Windows.UI.Xaml.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\ninput.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\advapi32.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\wininet.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\urlmon.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\d3d11.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\uxtheme.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\WinTypes.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\UIAutomationCore.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\twinapi.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\iertutil.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\dxgi.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\cryptsp.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\rsaenh.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\actxprxy.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\Windows.UI.Immersive.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\dui70.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\dwmapi.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\DWrite.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\d2d1.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\dxgidebug.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\d3d10warp.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\igd10umd32.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\MrmCoreR.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\profapi.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\BCP47Langs.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\Windows.UI.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\dcomp.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\msftedit.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\Windows.Storage.ApplicationData.dll'. Cannot find or open the PDB file.

    First-chance exception at 0x76F456C4 (KernelBase.dll) in tkos2.exe: 0x40080201: WinRT originate error (parameters: 0x8000000B, 0x00000040, 0x07A3F160).

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\Windows.Globalization.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\Winlangdb.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\WindowsCodecs.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\PhotoMetadataHandler.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\propsys.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\Windows.ApplicationModel.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\mfplat.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\cfgmgr32.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\avrt.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\MFMediaEngine.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\mfcore.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\ksuser.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\mfmp4srcsnk.dll'. Cannot find or open the PDB file.

    The thread 0xb0c has exited with code 0 (0x0).

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\mfsvr.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\bcrypt.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\MMDevAPI.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\devobj.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\AudioSes.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\msvproc.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\MSAudDecMFT.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\slc.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\RESAMPLEDMO.DLL'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\msdmo.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\COLORCNV.DLL'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\msmpeg2vdec.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\winmm.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\ws2_32.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\crypt32.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\winmmbase.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\nsi.dll'. Cannot find or open the PDB file.

    'tkos2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\msasn1.dll'. Cannot find or open the PDB file.

    First-chance exception at 0x76F456C4 in tkos2.exe: Microsoft C++ exception: _com_error at memory location 0x0BB2F18C.

    Unhandled exception at 0x6047978E (Windows.UI.Xaml.dll) in tkos2.exe: 0xC0000602:  A fail fast exception occurred. Exception handlers will not be invoked and the process will be terminated immediately.

    Monday, June 25, 2012 1:44 PM
  • Hi Rob and David,

    It appears that the RC release of both Windows 8 and Visual Studios fixed the problem. I am now able to doubletap and doubleclick without any problems.

    Monday, July 02, 2012 5:27 PM