I try to publish a site to: http://lolacyclingclub.org/ , but I get this error:
Error 2 Copying file bin\DotNetOpenAuth.AspNet.xml to obj\Release\Package\PackageTmp\bin\DotNetOpenAuth.AspNet.xml failed. Could not find file 'bin\DotNetOpenAuth.AspNet.xml'. 0 0 Lolabike
What exactly you have to do?
I found something that I have to delete the bin folder? Is that correct because it seems strange?
I see now this error:
Internal Server Error
The server encountered an internal error or misconfiguration and was unable to complete your request.
Please contact the server administrator to inform of the time the error occurred and of anything you might have done that may have caused the error.
More information about this error may be available in the server error log.
Web Server at lolacyclingclub.org
I dont know this error. has it to do read/write permissions? Or something like that?
I had similar problem. I referenced some libraries (which had reference to another libraries) in my ASP.NET web application. Unfortunately after project rebuild dll's which were previously copied to bin folder were deleted. This caused publish problem very similar to your problem. Solution was to copy all needed files to bin folder. I guess you need to put your files back to bin folder and it will publish successfully.
Deleting bin folder is not an option - these files are needed;)
Related
I am trying to publish my website in VS 2015, but I am receiving the following error:
Copying file Views\Shared\_StockQuotePartial.cshtml to
obj\Release\Package\PackageTmp\Views\Shared\_StockQuotePartial.cshtml
failed. Could not find file 'Views\Shared\_StockQuotePartial.cshtml'.
I have checked the Views\Shared folder (with all items showing) and no file named _StockQuotePartial.cshtml exists. I have also deleted the obj and bin folders and attempted to republish, but with no success. In addition, I have looked for references in the .csproj file and found non.
Any idea as to why I am getting this error for a file that does not exist / how I can resolve it?
Try to rebuild the project and then publish it ..
Background:
I am trying to use my office machine, where I have some limited rights, from home. All products are installed through when I was connected with my network drives, where my profile exists.
Now, I am at home where I don't have an access to these network drives.
Problem:
Whenever I am trying to create a project in visual studio I am getting the following errors:
---------------------------
Microsoft Visual Studio
---------------------------
Package 'ProviderPackage' failed to load.
---------------------------
Finding:
After doing some research I found that it is due to IISExpress. I have ensured that from Tools > options > Web project that IIS express is not enabled for all new web project.
I also got an error as:
---------------------------
Microsoft Visual Studio
---------------------------
Configuring IIS Express failed with the following error:
Filename: redirection.config
Error: Cannot read configuration file
---------------------------
Then I realized that may be it is not able to instantiate with IIS. Then I have tried to run an IIS express from the command prompt and I got this error:
C:\Program Files\IIS Express>iisexpress.exe
An error occurred while reading configuration information. Make sure
that the configuration file
\NAUNSW001\MalhAm\IISExpress\config\applicationhost.config exi sts,
it is accessible, and contains valid configuration information.
I don't have an access to the registry where this path might be picked by the IISexpress.
I have tried to execute the IISexpress /path: c:\vs\ it worked.
However, even then also when I am trying to create a new project I got an error as:
---------------------------
Microsoft Visual Studio
---------------------------
Configuring IIS Express failed with the following error:
Filename: redirection.config
Error: Cannot read configuration file
Alright - I am able to find the workaround.
If you find this error coming then probably it is to do with the IISExpress or IIS configuration that you may not be able to control from home.
The workaround that I have found is that:
Create Project,
System will not be able to attach the project, however it has been created. Then browse to that directory where the project has been created, and open the project file in the notepad or any editor.
Make sure that <UseIISExpress>false</UseIISExpress>
Before modifying further in the project file, Create a virtual directory in your IIS and point to the project path.
find <WebProjectProperties> in your project file config.
Define the virtual directory path under IISUrl.
Your config file should look something like this:
<WebProjectProperties>
<UseIIS>True</UseIIS>
<AutoAssignPort>True</AutoAssignPort>
<DevelopmentServerPort>0</DevelopmentServerPort>
<DevelopmentServerVPath>/</DevelopmentServerVPath>
<IISUrl>http://localhost/YourAppAlias/</IISUrl>
<NTLMAuthentication>False</NTLMAuthentication>
<UseCustomServer>False</UseCustomServer>
<CustomServerUrl>
</CustomServerUrl>
<SaveServerSettingsInUserFile>False</SaveServerSettingsInUserFile>
</WebProjectProperties>
Please use the following path :
Go to MyComputer>Documents>IISExpress>config>applicationhost.config
Right click on applicationhost.config and go to "Properties" option.
Now click advanced button and uncheck Encrypt contain security data.
Hope this will solve your problem...!!! :)
I had the similar issue could not even start a web project in vs 2013.
None of solutions suggested worked
So i tried the following
Gave read & write permission to following folder
C:\Program Files (x86)\IIS Express\config(default installation iisexpress8)
made sure both subfolders schema and template have read & write access
Then went in to schema folder and renamed asp net_schema.xml and ran iisexpress.exe from command prompt.
It started iis express and successfully registered url "xxxx" for site "webisite1" application
After that i quit iisexpress and renamed the schema file again to the old name.
After that i had no issues starting a web project
I found this it in a strange manner!
look for the IIS config file in my case it was.
C:\Users\\OneDrive\Documents\IISExpress
But accidentally my One Drive was paused. So it was able to access that files in the folder below.
C:\Users\\OneDrive\Documents\IISExpress\config
So just make sure IIS has access to configuration files.
open C:\Program Files (x86)\IIS Express\config.
open schema folder and rename ASPNET_schema (e.g ASPNET_schema1)
copy in run and hit enter "C:\Program Files (x86)\IIS Express\iisexpress.exe" /userhome:c:\temp\iisexpress
and you are all done. enjoy
I recently switched computers and copied all my projects over to my new local drive. I reformatted the computer I'm on now so it was pretty much a clean machine. Everything seemed to be working fine, but when I opened one of my projects that I had been running from my old machine, it would no longer compile, and I get the following error message:
Could not write to output file 'c:\Users\user\Documents\Projects\RegressionWeb\OnetouchUpload\obj\debug\OneTouchUpload.dll' -- 'Access is denied.'
I'm getting an error like that for each project I have in my solution. I'm also getting this error:
Unexpected error creating debug information file 'c:\Users\user\documents\projects\RegressionWeb\RegressionWeb\obj\Debug\RegressionWeb.PDB' Access is denied
I've searched high and low, and the only similar issues I could find online related specifically to ASP.NET and IIS, neither of which has anything to do with my project (My projects are class libraries of mostly NUnit tests with some support classes).
I am the administrator on my local machine. I have already taken ownership of every file in the project using takeown /f .\RegressionWeb /r /d y and also tried to ensure that nothing had a status of Read-only, but the following file threw an error when I tried changing the read-only property of it's parent folder:
An error occurred applying attributes to the file:
C:...\Regressionweb.sln.DotSettings.user
Access is denied
Basically this project was working perfectly and had no errors from my old computer. After copying over everything, this DotSettings.user file will not be modified, and Visual Studio can't write to any of the dll files. I'm sure the answer must lie in a Visual Studio setting somewhere. Any and all suggestions would be greatly appreciated.
I think Karl has it right. I had a similar situation once, and what I did was delete the file in question, clean the solution, and then rebuild. If the project needs that file it should recreate it; in my case it didn't need it because it never recreated it, but the project ran just fine.
One other thing I would recommend; you may be selecting the read-only attribute of the parent folder off and selecting this setting to recurse through all sub-folders and files, but that doesn't mean that's what's happening. For all your sub-folders and files (especially the ones that are cropping up as errors) inspect each one individually and make sure the read-only attribute is off.
My money is on your files are read-only. Verify they are read-only and change them or add your files to a source control system and let them get handled by that.
I was able to get this working by closing Visual Studio and then opening it again, but being careful to run Visual Studio "As Administrator". To do this, from the Start menu, right click on Visual Studio and choose "Run as Administrator".
it seems that the same error is sometimes displayed when the app pool user doesn't have access to the %TMP%/%TEMP% folder.
You'll need to grant IIS_IUSRS read and modify access over the temp folder of the user the app pool is running as.
This could either be the temp folder in the app pool user's profile, e.g. c:\Windows\ServiceProfiles\NetworkService\AppData\Local\Temp, or the system temp folder at c:\windows\temp.
See if it is related to this:Could not write to output file - Access is denied
. That would be a bit of a bugger to track down. In this case the project is self-referencing the dll and preventing access to the file.
This has a very simple solution, you just have to make sure that your directory name(folder name) is not the same as your file name. I created a folder by the name Pointers, my code was in a file pointers.cpp. When I compiled the code it kept showing the same error. I just had to change the directory or folder name to L1_pointers. You can change it to anything you want and it worked.
I have a WPF application . While building it I am getting the following error:
Could not load file or assembly or one of its dependencies. The parameter is incorrect. (Exception from HRESULT: 0x80070057 (E_INVALIDARG))
Application is trying to load the assembly from virtual drive (as debug Folder)
Ex: [subst r: c:[my Assembly bin pth]
Earlier I was mounting c:\bin as a netwwork drive and was getting te following error.
This assembly may have been downloaded from the Web. If an assembly has been downloaded from the Web, it is flagged by Windows as being a Web file, even if it resides on the local computer. This may prevent it from being used in your project. You can change this designation by changing the file properties. Only unblock assemblies that you trust. See http://go.microsoft.com/fwlink/?LinkId=179545 for more information.
Edit:
I am not able to find the Unblock button in properties window by the way.
Clear out the temporary framework files for your project in:
For Windows 7, the path is:
C:\Users\[username]\AppData\Local\Temp\Temporary ASP.NET Files\
For 64 bit systems with 'Framework' in the path the full path is:
C:\WINDOWS\Microsoft.NET\Framework64\v2.0.50727\Temporary ASP.NET Files\
http://www.solutioncottage.com/ShowSolution.aspx?solID=59
Removing all temp files from the path below still works, it saved my development site hosted on a web server from (HRESULT: 0x80070057 (E_INVALIDARG))
C:\WINDOWS\Microsoft.NET\Framework64\v4.0.30319\Temporary ASP.NET
Files\
On Visual Studio 2019 I was able to fix this manually deleting the ".vs" folder into the solution directory.
Thanks
this happened to me when i got a blue screen while building.
i had to delete my packages and bin folders, and get then from TFS
at that time i had nothing in the following location...
C:\Windows\Microsoft.NET\Framework\v4.0.30319\Temporary ASP.NET Files
to resolve i set Visual Studio in debug mode and then monitored the above directory. i deleted the files as they appeared and then the app started working again.
time to start looking for a new Dev machine.
For the Error which you were getting when you were mounting is due to blocking for Assemblies/DLL. Right click on what ever DLL's you have downloaded and you will get an option to unblock it .
For the Could not load file or assembly or one of its dependencies error, put a breakpoint in the constructor of the starting class and check it is failing due to what.
I was encountering this problem after a windows 8 blue screen error while building my wcf service. I tried all suggestions above.. but it didn't solve the problem.
Lastly, I removed and recreated the new application from IIS on the same wcf project.
Then every thing works fine.
Quoting this SO answer:
This can happen while referencing COM wrapper dlls.
Go in your Visual Studio Project, under References, select the referenced COM wrapper assemblies, right click, preferences, and make sure that Embed Interop Types and Specific Version are both set to False.
#Ernest 's answer worked for me on Visual Studio 2022
On Visual Studio 2019 I was able to fix this manually deleting the ".vs" folder into the solution directory.
I am getting below mention error in VS 2010. After getting this, Just restarting my machine and its working fine. But while hosting my application in windows server 2008 + IIS 7.0 its not working. Could you please suggest.
Error 107 Unable to copy file "C:\Inetpub\wwwroot\solution\Data.dll" to "bin\Debug\Data.dll". The process cannot access the file 'bin\Debug\Data.dll' because it is being used by another process.Services
Error 106 Unable to copy file "C:\Inetpub\wwwroot\source\Business.dll" to "bin\Debug\Business.dll". The process cannot access the file 'bin\Debug\Business.dll' because it is being used by another process.Services
You are compiling the application while it is running and IIS is using the DLLs.
The result is that the compiled DLLs cannot be copied because IIS is using them.
Reset IIS (or at least recycle the relevant application pool) before compiling.
You may want to reconsider setting the IIS web application folder to the project output folder.
Please check your Build Configurations under (VS2010) Build->Configuration Manager.
All projects should be in Debug or Release mode, and also check that the project Build check box is checked correctly.
Command prompt
copy source destination give full path of destination
copy C:\Inetpub\wwwroot\solution\Data.dll" "bin\Debug\Data.dll"
this is for copying file on the the same computer