Xamarin Android异常会导致“框架不在模块中" [英] Xamarin Android Exception causes "Frame not in module"

查看:73
本文介绍了Xamarin Android异常会导致“框架不在模块中"的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我是Xamarin的新手,目前正在用Android开发我的第一个应用程序.

I am new to Xamarin and currently developing my first app with Android.

我故意创建了一个异常,如下所示:

I have deliberately created an exception as follows:

throw new Exception("Whoops");

当我碰到这一行时,仿真器没有任何迹象表明存在问题.如果我在Visual Studio的上述行中设置了一个断点,然后跨过它,则会收到以下错误:

When I hit this line, the Emulator does not give any indication that there has been a problem. If I set a breakpoint on the above line in Visual Studio and then step over it, I get the following error:

框架不在模块中在已加载的模块中找不到当前的堆栈框架.

Frame not in module The current stack frame was not found in a loaded module.

如何使Visual Studio准确告诉我出了什么问题?目前,我找不到任何异常的痕迹.

How can I get Visual Studio to tell me exactly what went wrong? At the moment I can't find any trace of the exception.

推荐答案

此链接告诉我我需要知道的内容: https://developer.xamarin.com/guides/android/deployment,_testing,_and_metrics/android_debug_log/

This link told me what I needed to know: https://developer.xamarin.com/guides/android/deployment,_testing,_and_metrics/android_debug_log/

您只需从Visual Studio中转到查看">其他Windows">"Android设备日志记录".我发现最好使用文本视图.

You just go to View > Other Windows > Android Device Logging from within Visual Studio. I found it best to use text view.

如果有更好的方法,请让我知道.

If there is a better way then please let me know though.

这篇关于Xamarin Android异常会导致“框架不在模块中"的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆