Monday, February 16, 2009

Installing IIS 7.0 after installing VS 2008

If you have done the above, then you are not able to deploy WCF in the IIS. The solution is simple . Run the following command from Command Prompt:

%WINDIR%\Microsoft.Net\Framework\v3.0\Windows Communication Foundation\ServiceModelReg.exe" -r

This command registers the required script maps in IIS.

This command must add .svc file mapping but it is better to make sure if it is mapped to aspnet_isapi.dll.

How to Configure Namespace Reservations for WCF

After spending good amount time, things are little different when using WCF on Vista. Here is a command one should use , if you are getting following error.

"HTTP could not register URL Your process does not have access rights to this namespace (see http://go.microsoft.com/fwlink/?LinkId=70353 for details)"

Solution is to run this statement from command prompt with Administrator privileges. This statement assumes that you have created virtual folder called wcftest in IIS and WCF service is listening to port 8181.

C:>netsh
nash>http add urlacl url= http://+:8181/wcftest user = machine_name\shashank
nash>exit
C:>_