C# HttpListener without using netsh to register a URI

Posted by Chris T on Stack Overflow See other posts from Stack Overflow or by Chris T
Published on 2010-04-06T07:46:03Z Indexed on 2010/04/06 7:53 UTC
Read the original article Hit count: 931

Filed under:
|
|
|

My application uses a small webserver to server up some files and have a web interface for administration remotely. Right now the user has to use netsh to register the URI like so

netsh http add urlacl url=http://+:1233/ user=Chris-PC\Chris

Which is no fun for the average user. I'd like the program to be able to listen on any port specified by the user from my program without the end-user needing to using command prompt. Is there anyway to accomplish this short of just using Process.Start and running command prompt myself?

© Stack Overflow or respective owner

Related posts about c#

Related posts about http