Get ASP.NET Development Server Port Number

I need to get the asp.net development server port number in a C # method. Could you help me?

+3
source share
1 answer

You can get it from the request:

Request.Url.Port

And this is not strictly a development server web server, it is the port of the currently used web server.

+10
source

All Articles