Web Dev Matters and Me

Web Development Matters - HTML, XML, C#, .NET, AJAX/Javascript(jQuery), CSS, XML-XSLT

ME - LIFE,Philippines, Tokyo, ECE, PhilNITS/JITSE,情報処理, 日本語

things about Philippines, gaming, C# development and web development, how to make money in stock trading

Web Dev Matters and Me

Deploying WCF to IIS Server 7.5

I had to take few minutes to figure out how to deploy Virtual Applications, etc in IIS 7.5 . For me, deploying web applications and services in IIS 5 and 6 is easy, but maybe Microsoft did something new in IIS 7, that can improve the way we develop in .NET technologies.

Although, I still believe that a Web Service doesn't differ much to a Web Application (web service just do the XML parsing and header checking for you), Microsoft really did add awesome features in webservices/wcf framework. I liked doing the classic way, but most of the time utilizing the ready made framework is easier.

Let's start with WCF package deployment.

1. First, you have to build a deployment package. (Right click the solution to 
 choose it).
2. Once the build is successful, locate the project folder and look for the deployment package on the Debug folder. There are zipped version and the Files and Folder version, which you can simply take to the server.

3. Once you have placed the files on your server, you have to add necessary permissions that will allow IIS to serve your WCF solution. (Network Service, Machinename/IIS_IUSRS)

4. You may add an application pool if you want your WCF solution to have its own application pool (isolated from other application pool, which means there are certain amount of server resources allocated for your WCF). 

5. Add an application , referencing the directory of your WCF solution.

If you followed this steps, your WCF should be displaying the instruction to get the proxy code (svcutil.exe etc.).

Otherwise, you might bump on this problems.

HTTP Error 500.19 - Internal Server Error
The requested page cannot be accessed because the related configuration data for the page is invalid.
IIS Web Core
Not yet determined
Error Code
Config Error
Cannot read configuration file due to insufficient permissions

Or this one

Unrecognized attribute 'targetFramework'. Note that attribute names are case-sensitive.

Solution to the Cannot read configuration file due to insufficient permissions 
- Just convert the WCF directory to an Application.

Solution to the Unrecognized attribute 'targetFramework'. Note that attribute names are case-sensitive

-Check the application and see if it is running .NET Framework 4.0. When I checked mine, it was default to .NET 2.0



FB Connect