This project is read-only.


Can't install any package using nuGet package manager in Visual Studio


I just updated the nuGet Package manager. The version number is 2.2.40... Now, I am trying to install one package using nuGet Package Manager. and it is throwing an error. It is happening with only one web project. I have other web projects where I could install that package successfully. The error message is below:

" Access to the path 'C:\Users\kpatel\documents\visual studio 2010\Projects\CorpEmailManager\CorpEmailManager\packages.config' is denied. At line:1 char:16 + Install-Package <<<< Microsoft.AspNet.Mvc.FixedDisplayModes + CategoryInfo : NotSpecified: (:) [Install-Package], UnauthorizedAccessException + FullyQualifiedErrorId : NuGetCmdletUnhandledException,NuGet.PowerShell.Commands.InstallPackageCommand"

I am attaching my package.config file also.

Thanks in advance for help.

file attachments

Closed Feb 28, 2013 at 10:52 PM by dotnetjunky


JeffHandley wrote Feb 21, 2013 at 11:53 PM

Have you tried explicitly checking the file out from TFS before doing the install-package? This seems like the file is marked as readonly and cannot be edited by NuGet when the package is being installed.

Since this is only happening in a single project, it seems like there's something wrong with that particular file. Are you able to check the file out and edit it through VS yourself, or even notepad?

knpatel wrote Feb 22, 2013 at 4:54 PM

I added the .dll file manually, and also added the entry into package.config file. But still Opera Mini browser is not loading view. I think it is still not recognizing mobile browser. Please help out to solve this issue.

Please check the attachment.


JeffHandley wrote Feb 22, 2013 at 5:32 PM

We cannot help with the function of the actual assembly. For that, you'll need to log an issue on the ASP.NET Web Stack, here:

I'd like to help you resolve the "cannot install the NuGet package" problem though. Since you're able to modify the packages.config file yourself, I presume you got past the file being locked. Are you now able to install/uninstall packages using NuGet?

knpatel wrote Feb 22, 2013 at 7:19 PM

Ok. Thanks for reply. I will post this issue to web stack.

dotnetjunky wrote Feb 26, 2013 at 6:14 PM

Can you answer JeffHandley's question below? Are you able to check out the file and install nuget packages afterwards?

knpatel wrote Feb 26, 2013 at 11:52 PM

I uninstalled NuGet Package Manager. And re-installed it. And I could install required package.