I have a control that i am loading in to IE to access data from another server. When the control runs i get this error:
System.Security.SecurityException: Request for the permission of type 'System.Net.WebPermission, System, Version=18.104.22.168, Culture=neutral, PublicKeyToken=b77a5c561934e089' failed. at IECameraViewer.UserControl1.timer1_Tick(Object sender, EventArgs e) at System.Windows.Forms.Timer.OnTick(EventArgs e) at System.Windows.Forms.Timer.TimerNativeWindow.WndProc(Message& m) at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam) The action that failed was: Demand The type of the first permission that failed was: System.Net.WebPermission The Zone of the assembly that failed was: Trusted
The code runs in the control debugger with out any issues but fails when it is run in IE. I have made sure that the site that the page loads from and that the controll requests data from are both in the trusted sites list.