智能感知不工作的子工程的NuGet包

问题描述 投票:0回答:1

我有以下文件夹结构的Azure的功能项目:

VS Code folder structure

SyncAgent.Data子项目与命令dotnet new classlib --framework netcoreapp2.2创建

在同一目录下,然后我跑到dotnet add package Microsoft.Azure.DocumentDB.Core安装DocumentDB封装为Data子项目。

DocumentRepository类包含代码连接到CosmosDB并添加文件。该SyncAgent.csproj文件包括SyncAgentData.csproj。在SyncPartnerCustomers类内部的Azure的函数调用的DocumentRepository类代码。

当使用VS代码调试的代码运行与没有错误预期执行。问题是,智能感知不能识别的子项目的Microsoft.Azure.Documents命名空间。

VS Code IntelliSense errors

为什么智能感知不能检测命名空间,尽管代码运行而不会出现错误的事实呢?

c# visual-studio-code .net-core nuget intellisense
1个回答
1
投票

不知道什么是错的,但删除所有临时binobj文件夹重新启动VS代码和重新建设,该项目似乎解决这个问题。

© www.soinside.com 2019 - 2024. All rights reserved.