During the debugging, you can attach the current code from Visual Studio to hosted web service or application. This helps to debug the code in Visual Studio while requests are coming to IIS web service or application. However, this is possible only when you know the Process Id.
The below command display the list of process ids running under IIS:
You can get the result as: