Tuesday, 9 July 2013

Solution for Serialization.dll is not found in Temp Folder in Asp.Net Web Service

                Asp.Net developers some times would seen this issue "Serialization.dll is not found in the Temp folder" Error.

What is happening here , when calling a web service through a soap request from a web page will generate a dll in runtime to serialize and deserialize the response.This dll will be generated in Temp Folder of the system.
Some times this XmlSerializer.dll is not found in that particular location because of the following reasons.

1. Doesn't have a Permission to create the DLL.
2. Dll will create and automatically deleted , This is because of the Antivirus. Antivirus will consider this dll as Serialization.dll Virus.

How to Overcome this issue ?

 Instead of Generate the XmlSerializer.dll in runtime , we make a static dll. Which is Pre-Generated XmlSerialization.dll and binded with the Proxy class . instead of calling a WebService through soap request , Make proxy Dll and pass the Url of the webservice as parameter in the cosntructor and call the webservice from that Proxy class.

To achieve that refer the steps present in following link 

This is the Solution to avoid the XmlSerializer.dll not found error at runtime.