English 中文(简体)
Error “dotnet”: 在Microsoft的“C:**”操作“dotnet”添加包裹时,找不到任何项目。 AspNetCore.Authentication.MicrosoftAccount”
原标题:Error "dotnet : Could not find any project in `C:**." when running "dotnet add package Microsoft.AspNetCore.Authentication.MicrosoftAccount"

我有视力演播室2019年,我设立了一个新的像样核心2.2项目。 现在,我遵循这些步骤:,使外部标识能够用于我们的网络应用。 但当我指挥时:

dotnet add package Microsoft.AspNetCore.Authentication.MicrosoftAccount

i 反映这一错误:

PM> dotnet add package Microsoft.AspNetCore.Authentication.MicrosoftAccount dotnet : Could not find any project in C:Users*****source eposMSlogintest. At line:1 char:1 + dotnet add package Microsoft.AspNetCore.Authentication.MicrosoftAccount + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + CategoryInfo : NotSpecified: (Could not find ...MSlogintest`.:String) [], RemoteException + FullyQualifiedErrorId : NativeCommandError Usage: dotnet add package [options]

Arguments: The project file to operate on. If a file is not specified, the command will search the current directory for one. The package reference to add.

Options: -h, --help Show command line help. -v, --version The version of the package to add. -f, --framework Add the reference only when targeting a specific framework. -n, --no-restore
Add the reference without performing restore preview and compatibility check. -s, --source The NuGet package source to use during the restore. --package-directory The directory to restore packages to. --interactive
Allows the command to stop and wait for user input or action (for example to complete authentication).

as follow:- enter image description here

and when i access the folder, i found that there is a VS project folders, as follow:- enter image description here

so why the error is saying that it can not find any project? can anyone advice on this error please? Thanks

问题回答

我遇到了同样的问题,并找到了解决办法。 首先,全面和仔细阅读错误信息。 它说:

“不可能找到任何项目......”

这就意味着它期望得到项目信息。 如果你进一步密切观察这一信息,它就提到正确使用这一指挥系统,即:

使用:

在争论中,进入你的项目名称并再次管理。 此时,你们应当看到成功的信息类似于:

参考:将Microsoftxxxxxxxxxxxxxx并入项目 C:Usersxxxsource epos Folderxxxxxxxxxxcsproj 。

“demonstration

在权力方面开展工作。 解决办法在某些地方隐藏在评论中,但这里很容易:

<编码>dotnet 添加和提炼;项目> 包装和包装; 姓名和编号;

在这种情况下,我认为:

dotnet Add ContosoUniversity Packsoft.AspNetCore.Authentication.MicrosoftAccount

c 列入你希望将一揽子计划添入和打上你的蚊帐指挥系统。

> cd project Directory
> dotnet add package Microsoft.AspNetCore.Authentication.MicrosoftAccount

这支指挥部负责。 NET 核心。 我将该项目用于一个老项目,因为它是第一个在核心领域显示的项目。

旧指挥部也这样做:

Install-Package [package name]

Had the same problem, when i was fiddling around with the nuget commandline it at some point proposed i should retry with elevated privileges. Specifically i tried manually pointing it one level deeper in the folder structure. (As suggested by DavidG)

我认为:oka、 we,但出于好的想法,让我们尝试。

重新开始担任管理人。

它的工作意味着它刚刚奏效,没有涉及手工交易。 我刚刚利用了只有一些how的图形一揽子管理人员选择。

因此,我在安装视力演播室时,最好的猜测就是说什么。 因为我已经尝试过一次新项目。

Nuget option as admin

您可能会被点击到树苗现场的错误表格。 • 确保挑选一揽子管理人员。 当你点击.蚊帐并在包裹管理人 con窗上使用时,就会出现错误。

在您的指挥大楼里,你应进入一个目录项目:

蚊帐添加包装和包装;包装。 名称和编号;





相关问题
Anyone feel like passing it forward?

I m the only developer in my company, and am getting along well as an autodidact, but I know I m missing out on the education one gets from working with and having code reviewed by more senior devs. ...

How to Add script codes before the </body> tag ASP.NET

Heres the problem, In Masterpage, the google analytics code were pasted before the end of body tag. In ASPX page, I need to generate a script (google addItem tracker) using codebehind ClientScript ...

Transaction handling with TransactionScope

I am implementing Transaction using TransactionScope with the help this MSDN article http://msdn.microsoft.com/en-us/library/system.transactions.transactionscope.aspx I just want to confirm that is ...

System.Web.Mvc.Controller Initialize

i have the following base controller... public class BaseController : Controller { protected override void Initialize(System.Web.Routing.RequestContext requestContext) { if (...

Microsoft.Contracts namespace

For what it is necessary Microsoft.Contracts namespace in asp.net? I mean, in what cases I could write using Microsoft.Contracts;?

Separator line in ASP.NET

I d like to add a simple separator line in an aspx web form. Does anyone know how? It sounds easy enough, but still I can t manage to find how to do it.. 10x!

热门标签