This article by Chris Sells might help:
http://msdn.microsoft.com/library/en-us
/dnforms/html/winforms11122002.asp
Thanks,
Shawn Wildermuth
http://adoguy.com
C# MVP, MCSD.NET, Author and Speaker
-----Original Message-----
From: Discussion forum for developers using Windows Forms to
build apps and
controls [mailto OTNET-WI
NFORMS DISCUSS.DEVELOP.COM] On Behalf Of Pradeep
Tapadiya
Sent: Tuesday, May 09, 2006 10:21 PM
To: DOTNET-WINFORMS DISCUSS.DEVELOP.COM
Subject: [DOTNET-WINFORMS] MethodAccessPermission
.NETters,
Our application is a WinForms user control that gets hosted
in IE. This user
control contains a DataGridView control among other
controls. Our control
was getting downloaded just fine under IE, that is, until we
added a
DataGridViewLinkColumn column to the datagrid. IE's error
log suggests a
MethodAccessException.
The server the control is downloaded from is in the
"Local Intranet" zone.
It must have all the necessary privileges.
Any suggestions?
Thank you in advance for your help.
Pradeep
----
Microsoft.IE.SecureFactory:
System.Reflection.TargetInvocationException:
Exception has been thrown by the target of an invocation.
--->
System.MethodAccessException: Attempt to access the method
failed.
at System.RuntimeTypeHandle.CreateInstance(RuntimeType
type, Boolean
publicOnly, Boolean noCheck, Boolean& canBeCached,
RuntimeMethodHandle&
ctor, Boolean& bNeedSecurityCheck)
at System.RuntimeType.CreateInstanceSlow(Boolean
publicOnly, Boolean
fillCache)
at System.RuntimeType.CreateInstanceImpl(Boolean
publicOnly, Boolean
skipVisibilityChecks, Boolean fillCache)
at System.Activator.CreateInstance(Type type, Boolean
nonPublic)
at System.Windows.Forms.DataGridViewLinkColumn.Clone()
at
System.Windows.Forms.DataGridView.CorrectColumnFrozenStates
(DataGridViewColumn[] dataGridViewColumns)
at
System.Windows.Forms.DataGridView.OnAddingColumns(DataGridVi
ewColumn
[] dataGridViewColumns)
at
System.Windows.Forms.DataGridViewColumnCollection.AddRange
(DataGridViewColumn[] dataGridViewColumns)
-----
|