Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
Question
Tuesday, December 11, 2012 3:10 PM
I am using VS 2010 with TFS and I am trying to publish my web application project to our local webserver. I tried both to our IIS7 and our IIS6 webservers with the same results. When I click Publish I get the following error for any web page I have changed since the last publish. This just started happening and not sure what is cause. Thanks.
Publish started: Project: ClinicAccounting, Configuration: Debug Any CPU
Connecting to R:\ClinicAccounting...
Transformed Web.config using Web.Debug.config into obj\Debug\TransformWebConfig\transformed\Web.config.
Copying all files to temporary location below for package/publish:
obj\Debug\Package\PackageTmp.
Publishing folder /...
Unable to add 'SearchHome.aspx' to the Web site. Unable to add file 'SearchHome.aspx'. Access is denied.
etc...
All replies (7)
Wednesday, December 12, 2012 2:50 PM ✅Answered
Turned out to be a problem with the application dll etc. files. I blew them away and did a Build and then Publish and all worked fine.
Tuesday, December 11, 2012 4:59 PM
Why dont you build your project and then manually copy all files using remote desktop connection or filezilla?
Tuesday, December 11, 2012 5:03 PM
I tried that and got the same error, even with administrator login. Doesn't the Publish do some things besides a straight copy of files? I am not sure what files do not need to be copied.
Wednesday, December 12, 2012 7:35 AM
I have my project running without every publishing through VS. I always build the project then copy the entire folder including all items in the bin folder. After that if I change a design form I just copy the form, otherwise if I change code I need to rebuild and then copy the 3 items in the bin directory as well as the aspx item with the code change – be careful as this will drop users currently using the website.<o:p></o:p>
However I think you problem is outside VS because you need to be given full permission and if you cannot copy using RDP or filezilla then you will not be able to copy using VS. <o:p></o:p>
Try creating a new folder on the server in case the folder items are locked. If you can RDP you can simple copy and paste like you would to a memory stick from your PC to the new folder on the server. If this works repoint you IIS website to this new folder.<o:p></o:p>
Hope this helps you.<o:p></o:p>
Wednesday, December 12, 2012 10:38 AM
Am I correct in assuming only .aspx files are copied? My project folder has .aspx and .aspx.vb and .aspx.designer.vb
If I copy everything then I may get files not needed, correct? How does someone know exactly what files get copied.
Wednesday, December 12, 2012 10:58 AM
All files need to be copied - .aspx and .aspx.vb and .aspx.designer.vb as they reference each other, they are small in size so wont take up much space on server.
Wednesday, December 12, 2012 12:20 PM
That is kind of a pain. Now I have to keep track of all pages I change and then copy them to webserver before I can test. I also assume I have to copy the application dll after every build...?
I also noticed that the file [MyApplication].dll is in both the \bin folder and also in the \obj\Debug folder.