Step 1: Add Inbound Rule of Windows Firewall

  1. Add Inbound Rule of Windows Firewall
  2. Open the Windows Firewall with Advanced Security. 
  3. At the left panel, right click on Inbound Rule > New Rule 
  4. Rule Type: Port 
  5. Protocol and Ports: TCP 
  6. Specific local ports: 57976 
  7. Action: Allow the connection 
  8. Profile: Tick all (Domain, Private, Public)
  9. Name: Name, Description(optional)
  10. Finish. 

 

Step 2 : In case of IIS Express

  1. Stop the current Site 
  2. For Visual Studio 2015, change the IIS config under your project folder C:\Projects\\.vs\config\applicationhost.config??.
  3. For previous version of Visual Studio 2015, change the IIS config under IIS Express folder C:\Users\\Documents\IISExpress\config\applicationhost.config 
  4. In applicationhost.config, search by the port number (for my case is 57976), then one more binding with your IP Address

Step 3: In case of IIS

  1. Open the IIS Manager. 
  2. At the left panel, Go to Sites > Default Web Sites.
  3. At the right panel, click on the Bindings. Then, the new dialog pop ups.
  4. At the pop-up dialog, click on the "Add" buttons. Input the port number and the hostname.
  5. For my case, 
  6. port = 57976;
  7. hostname = 192.XXX.XXX.XXX (my IP address)

Step 4: Finally, run the application in Visual Studio

  1. Close Visual Studio
  2. Right click on Visual Studio > Run as Administrator

 

blog comments powered by Disqus