I'm trying to publish a .NET 4.0 application to a web server using Visual Studio 2010 ClickOnce deployment. The actual application is published successfully, but if I start the installation from a machine without .NET 4.0 already installed, setup fails: When I click the download link, I'm getting the following error message:
An error occurred downloading the following resource:
http://server/app/DotNetFX40/dotNetFx40_Full_x86_x64.exe
A look at the published folder shows that Visual Studio created three folders there, next to setup.exe: Application Files, dotnetfx40 and windowsinstaller3_1.
If I change the actual directory name from dotnetfx40 to DotNetFX40, it works.
My "Publishing Folder Location" is a file path (\\\server\c$\... etc.), the "Installation Folder URL" is http://server/app.
I was surprised that I didn't find anything on this online; am I missing something obvious?
If your web server is a *NIX machine, then file names are case sensitive. This means that dotnetfx40 and DotNetFX40 are different files, which would explain why you got an error trying to download one (that didn't exist), and why the other worked.
Workaround: we switched over to copying the binaries from our build machine to the destination instead of deploying from dev machines.
Related
I have a C# MVC project in Visual Studio Express 2013. I'm using the Publish Web option and Web Deploy as the method.
After a bunch of work to get Web Deploy setup on the target machine, I finally got a valid connection:
Screenshot here (since I don't have the reputation to add the image to the post): http://screencast.com/t/Q5IccavcB1
However, when I actually publish, I get this error:
Web deployment task failed. (Connected to the remote computer ("myServerName.com") using the specified process ("Web Management Service"), but could not verify the server’s certificate. If you trust the server, connect again and allow untrusted certificates.
The help information I find is almost exclusively for VS 2010, which isn't very helpful here. I finally tried adjusting my .pubxml file by directly adding AllowUntrustedCertificate = True in the PropertyGroup, but that has no effect.
Screenshot:
Any ideas? I'm out of them.
Thanks!
Well, it turns out that an artifact left over from trying to get an MSBuild for TeamCity working was the cause of the problem.
upgraded from VS2010 to VS2013 now I cannot publish
I added back in the PropertyGroup that I removed yesterday, and I was able to publish.
adding /p:AllowUntrustedCertificate=true argument in msbuild.exe resolve my problem
How can resolve Untrusted certificates Error ?( TFS2013 Build and deploy to IIS )
I have an application that is built from a TFS Build server into a drop folder. The application builds with no errors reported. The application is in C# using .NET 4.5.1.
When I copy the deployment folder to my local desktop, the application runs fine.
However, when I copy the deployment folder to our internal server, I get the following error when trying to run:
error CS0006: Metadata file
'file:\NNNNSERVER\YourEXEFolder\log4net.DLL' could not be found
This error is repeated for all DLL's in the project and for the executable itself.
Other applications with similar profiles (C#, .NET 4.5.1) run fine on the same server. It seems to me to be pretty clear that its not the build or the code but something with the server or permissions, but I need to find something to tell our systems people.
My C# code loads a C++ DLL. It works fine on my PC, where Visual Studio 2008 is installed. But on other machines the program stop with an exception
Unhandeled exception: system.dllnotfoundexception unable to load dll ...
this application has failed becasue the application configuration is incorrect....
How can I make this code run on a machine that doesn't have VS 2008 installed?
You must distribute your DLL along with your project if it is a custom DLL of yours. If not, you must install the required DLL either with a custom installer or if it is from a different provider, a installer of them.
This post might be a bit older, but
DLL Files And .NET ClickOnce Deployment
I want to deploy one of my .NET apps as a ClickOnce application. The issue is that I am connecting to Oracle (see previous posts here and here). Connecting to Oracle requires at least, 4 DLL files that generally have to be in the same directory as the EXE file. The issue is that when the program is published, the DLLs are not referenced in any way, so the program won’t work.
Then I read about adding the files to the project, so that ClickOnce and the Publish processor will figure out that the DLLs are required and add them to the manifest.
Here is the process in Visual Studio 2005:
1. Put the 4 DLL files in their own directory in your solution directory (for ease of use mostly).
2. Add all four files to your project by going to “Project->Add Existing Item…”
3. Click on each DLL file in the solution explorer and then change their property: “Copy To Output Directory” to “Copy Always”.
That’s it! Now when I publish or even run the application I don’t have to worry about if the DLL files are where they should be.
in vs 2008 on project:
Properties>c/c++ >Runtime Library > choose: Multi-threaded Debug (/MTd)
I am developing C# (VS 2008) code in a SSIS Task (SQL Server 2008 R2) script that will automatically check in (using SPFile method) newly created Excel files into a SharePoint site after they are copied to the appropriate UNC path. Since I am developing on a computer that does not have SharePoint installed, I need to copy to my computer and register the Microsoft.SharePoint.DLL file (version 2010) in order to reference and apply its associated methods.
The problem I am having is that I am unable to register the Micrsooft.SharePoint.DLL file on my computer using Windows 7 and was hoping that somebody can assist.
Here is what I've done so far and with the following results:
Copied Microsoft.SharePoint.DLL to folder C:\Windows\System32 and verified that the file is present.
Verified that regsvr32.exe is located in folder C:\Windows\System32.
Ran the following command in C:\Windows\System32 with the following result:
regsvr32 Microsoft.SharePoint.DLL
Box pops up with following message:
'The module "microsoft.sharepoint.dll" was loaded but the entry-point DllRegisterServer was not found. Make sure that "microsoft.sharepoint.dll" is a valid DLL or OCX file and then try again.'
The DLL file was provided by the SharePoint administrator.
I have also rebooted my computer, as recommended on some other IT sites, but that has made no difference.
Until I can register the Microsoft.SharePoint.DLL file, I cannot apply it as a reference in my code. Can somebody assist?
Thanks.
That is impossible by design. Developing and/or running SharePoint-related code on a machine where SharePoint isn't installed is not supported and there is no workaround.
In case you must do it like that and you target SharePoint 2010, consider using client object model.
Everytime I try to compile in Visual Studio 2010 I get the error
Unable to launch the ASP.NET Development server. Unable to start program 'C\path.......\Webdev.Webserver40.exe
I also tried to execute this file (Webdev.Webserver40.exe) and I get this error:
WebDev.WebServer40.exe is not a valid win32 application
I already turned off every firewall I have, and I already tried changing the .NET framework of any project, changed to different speceific ports and it's still failing...
What could be happening?
I have Windows XP SP3
I went through the same error. Seems like somehow the webserver embebbed in VS2010 got corrupted.
If you try to Debug a WebSite, the error is "Unable to launch ASP.NET Development Server".
If you try to Debug a Web Application, the error message points to the path of the server.
It's installed under this folder:
C:\Program Files\Common Files\Microsoft Shared\DevServer\10.0
The two executables WebDev.WebServer20.EXE and WebDev.WebServer40.EXE were really corrupted (getting error "not a valid win32 application" when try to run).
I had to go to instalation DVD and selected "Change or Remove Microsoft Visual Studio 2010" in the Main Menu.
After that:
Add or Remove features
Uninstall Web Developer
When the uninstalling is complete, do it again:
Add or Remove features
Install Web Developer
Now everything works just fine.
I hope the same resolve to you.