How do I publish/deploy an asp.net website to a live server (like a goDaddy server)?
I moved all the files to the remote server without dataaccess layer and business layer. Move dlls to bin folder on live server. But when I try to browse website it gives errors like:
Could not load file or assembly 'BusLayer' or one of its dependencies. This assembly is built by a runtime newer than the currently loaded runtime and cannot be loaded.
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.
Exception Details: System.BadImageFormatException: Could not load file or assembly 'BusLayer' or one of its dependencies. This assembly is built by a runtime newer than the currently loaded runtime and cannot be loaded.
Please help me handle these errors. I am not very good at English; maybe there are a lot of mistakes in my question. Thanks in advance for help.
I assume Bus layer means business layer. I believe that your presentation layer has some dependencies on the business layer. Now since you didn't push the business layer to production (remote server), its looking for a file and not finding it and hence the error.
the fix i guess will be to move all your files to remote server and try browsing files that doesn't have database dependencies (Again, assuming you don't have a database at production)
"This assembly is built by a runtime newer than the currently loaded runtime and cannot be loaded." usually means that you have a .NET version issue. Is the BusLayer assembly on the server compiled under a newer version that the web site?
Also, does the app run locally? If so, publish all the contents of your local BIN.
I hope you made a backup of your site prior to deployment.
Related
I am a new bee to web services and I have to publish a web service to a server.
I added an application using IIS but when I try to browse the application it gives me this error.
Could not load file or assembly 'Microsoft.AI.Web' or one of its dependencies. The system cannot find the file specified.
I had seen other answers about this issue,where most of them are related to installing Microsoft.AI.Web package. This is already installed in my web service and I am still getting the error.
Thanks in advance for any suggestions to resolve this.
There was an update waiting on the Nuget package manager for Microsoft.ApplicationInsights, after updating it added the application again to IIS. This resolved my error.
I deployed my multi-tier application to azure. It was working perfectly, but now when I try to deploying it, it shows an error saying:
Could not load file or assembly 'MySomething.dll' or one of its dependencies. The process cannot access the file because it is being used by another process. (Exception from HRESULT: 0x80070020)
I checked other answers, but all of them dealing with IIS. Azure Web Apps IIS cannot be accessed directly. How can I resolve this?
As usual, this issue happened because of caching. Removing the bin/obj directories alongside the IIS Express cache folder fixed the issue.
I have unloaded the version free Community Edition from
http://selectpdf.com/html-to-pdf/demo/
Because I wanted to use the example that turned a page html into pdf.
In visual studio I have succeeded in using the file asp.net but when I put it online I receive this error:
Security Exception
Description: The application attempted to perform an operation not allowed by the security policy. To grant this application the required permission please contact your system administrator or change the application's trust level in the configuration file.
Exception Details: System.Security.SecurityException: That assembly does not allow partially trusted callers.
I have loaded the files on three different servers.
Azure, Aruba and Godaddy, but do I always receive the same error, as I can resolve?
http://pdf.cyberkings.fr/html-to-pdf-converter.aspx
http://www.numero-telefono.it/html-to-pdf-converter.aspx
Thanks
Conversion failure. Could not find 'Select.Html.dep'.
Description: An unhandled exception occurred during the execution of the current web request
When installing Select.HtmlToPdf from NuGET, the installation copies the dependancy file Select.Html.dep to the bin. When you build, a copy gets placed in the /bin beside Select.HtmlToPdf.dll.
However, when deploying your application, the dependency file does not get copied automatically.
You need to copy Select.Html.dep manually.
See the SelectPdf Html To Pdf Converter for .NET deployment documentation.
WebHost failed to process a request.
Sender Information: System.ServiceModel.ServiceHostingEnvironment+HostingManager/14938877
Exception: System.ServiceModel.ServiceActivationException: The service '/xxxx.svc' cannot be activated due to an exception during compilation.
I have an ASP.NET app running on IIS. A dev created operation contract with same name as we had already. Fine in VS. However it fails when deployed on the prod IIS.
My question - what it has to do with compilation? Is there a conscious simple explanation whats happening in IIS with the app (in terms of post-deployment and hosting ASP.NET att)? What does it compile? What for?
My question - what it has to do with compilation?
Every time you run a .net managed process, the first thing which has to happen is that the .net VM (called the CLR) will compile the code in your assemblies (called MSIL) into machine code.
So IIS, as the hosting container, is providing this service for you.
As to the actual error you are getting, I would guess this is caused by something in the production web.config file being different to the development equivalent. Please post the System.ServiceModel configuration section of your web config and I'll have a look.
I am trying to deploy an ASP.NET 5 application to my 64-bit Windows Server 2008 R2 server. I created a blank web application and set up a file system publish profile using dnx-clr-win-x64.1.0.0-beta4. I copied the results from the publish location to a folder on my server and created a new virtual directory with a .NET 4.0 app pool pointing at the wwwroot folder of my application. However, when I try to browse to the site, I get this error:
Could not load file or assembly 'dnx.clr.managed' or one of its
dependencies. The system cannot find the file specified.
Description:
An unhandled exception occurred during the execution of the current
web request. Please review the stack trace for more information about
the error and where it originated in the code.
Exception Details:
System.IO.FileNotFoundException: Could not load file or assembly
'dnx.clr.managed' or one of its dependencies. The system cannot find
the file specified.
The same steps on my local PC (where I have Visual Studio 2015 installed) work correctly so it seems like I need to install something else on my server. I have already installed .NET 4.6 on this server without success. Does anyone know what I am missing?
I found the solution thanks to this question: Azure deployment : Could not load file or assembly 'dnx.clr.managed' or one of its dependencies. The system cannot find the file specified
At first I thought that wasn't the answer because it didn't work when I changed my publish profile from dnx-clr-win-x86.1.0.0-beta4 to dnx-clr-win-x64.1.0.0-beta4. However, I later noticed that approot/packages folder didn't have the x64 package. So I deleted everything and re-published with my new profile and the page loaded.
Change the dependencies file to the current version, whether it is 1.0.0-beta7 or 1.0.0-beta6 ensure that you go to nuget package manager and install the appropriate version rebuild the solution you should see file updates from your output windows.