I can't find the solution to get this working, my trust level is on full
Description: The application attempted to perform an operation not allowed by the security policy. To grant this application the required permission please contact your system administrator or change the application's trust level in the configuration file.
Exception Details: System.Security.SecurityException: Request for the permission of type 'System.Net.SocketPermission, System, Version=126.96.36.199, Culture=neutral, PublicKeyToken=b77a5c561934e089' failed.
Line 1722: Dim target = New UdpTarget(New IpAddress("x.x.x.x"), 161, 1000, 0)
Thanks for any help,