none
my TcpListener.Start in win 7 could not work with win 10!! RRS feed

  • Question

  • I had written Socket Server program from win 10 to win 7 . and it work fine

    But when I change both, I wrote Socket Server program the same from  win 7 to win 10.

    This command failed:

           myTcpListener.Start()

    Because of access was denied by privilege  level

    Would some one Please resolved this?

    Monday, May 27, 2019 1:29 AM

All replies

  • What port number are you listening for?  Some of them do require privilege.  Have you poked a hole in your firewall?

    Tim Roberts | Driver MVP Emeritus | Providenza & Boekelheide, Inc.

    Monday, May 27, 2019 5:34 AM
  • I used 1030 port.

    By the way, how to poked a hole in my firewall. Is that in my firewall give a Input Rule for setting port.

    I'd all open with my firewall??

    The error message:

          System.Net.Sockets.SocketException: Access denied  because of privilege ...

    • Edited by ㄚ嬤 Monday, May 27, 2019 8:53 AM
    Monday, May 27, 2019 8:07 AM
  • Hi 

    Thank you for posting here.

    Based on your description, you want to solve the exception that access was denied by privilege level.

    The following link may be helpful for you to solve the problem.

    https://stackoverflow.com/questions/4019466/httplistener-access-denied​​​​​​​

    Best Regards,

    Jack


    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.

    Tuesday, May 28, 2019 1:52 AM