Pages

The TransportManager failed to listen on the supplied URI using the NetTcpPortSharing service

If you are starting fresh to WCF and trying to run service, you might an issue like this:

The TransportManager failed to listen on the supplied URI using the NetTcpPortSharing service: failed to start the service because it is disabled. An administrator can enable it by running 'sc.exe config NetTcpPortSharing start= demand'..System.ComponentModel.Win32Exception (0x80004005): The service cannot be started, either because it is disabled or because it has no enabled devices associated with it


The exception message is self-explanatory:

NetTcpPortSharing service is disabled on the machine you are trying to run service on. You can enable service by:

Solution:


  • Open cmd and Type 
  • sc.exe config NetTcpPortSharing start= demand
  • Press Enter

Or

  • Open Run Type services.msc and click OK
  • In Services window find Net.Tcp Port Sharing Service
  • Go to Properties and change the Startup type to Manual. 

good luck!!!