调试 - 在 Xamarin.Forms Android 应用程序 (VS 2017) 中引用 .NET 标准 1.4 库 [英] Debugging - Referencing .NET standard 1.4 libraries in Xamarin.Forms Android application (VS 2017)

查看:33
本文介绍了调试 - 在 Xamarin.Forms Android 应用程序 (VS 2017) 中引用 .NET 标准 1.4 库的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我使用 VS 2017.

I use VS 2017.

我有 Xamarin.Forms Android 项目,我必须在那里引用一堆 .NetStandard 1.4 库.我在一个解决方案中包含所有项目.

I have Xamarin.Forms Android project and I have to reference bunch of .NetStandard 1.4 libraries there. I have all projects in one solution.

我基本上没有问题地添加了引用和编译的解决方案.

I basically added references and compiled solution with no problem.

当我从 .Net Standard 库中包含的 Xamarin 方法调用时,它返回结果,但在该方法中没有断点.此外,VS 2017 智能感知不适用于 .NetStandard 库中包含的方法.

When I call from Xamarin method contained in .Net Standard library, it returns result but no breakpoint is hit inside that method. Also VS 2017 intellisense is not working for methods contained in .NetStandard libraries.

当从 Xamarin.Forms Android 应用程序调用 .Net Standard 库时,我是否需要做一些额外的事情才能在 .Net Standard 库中启用调试和智能感知?

Do I have to do something extra to enable debugging and intellisense in .Net Standard library when it's called from Xamarin.Forms Android application ?

我对此困惑了 2 天(起初我以为我的 .net 标准方法根本没有被调用),但我不知道该怎么做.

I was confused with this for 2 days now (first I thought my .net standard methods are not called at all) and I dont know what to do.

你能给我一些关于如何使调试和智能感知工作的建议吗?

Could you please give me some suggestions how to make debugging and intellisense working ?

谢谢.

推荐答案

我找到了解决方案.

您可以添加到您的 .netStandard 库 csproj 文件

You can add to your .netStandard library csproj file

<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
   <DebugType>Full</DebugType>
</PropertyGroup>

这将使调试工作.

这篇关于调试 - 在 Xamarin.Forms Android 应用程序 (VS 2017) 中引用 .NET 标准 1.4 库的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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