I get this error after upgrading from asp.net 1.1 to 2.0 in our web hosting.
"Request for the permission of type System.Security.Permissions.UIPermission, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 failed."
The page have add reference to System.Windows.Forms.dll.
Below is part of my code:
Dim x As Windows.Forms.Form = New Windows.Forms.Form
Dim grp As Graphics = x.CreateGraphics()
Dim stringFont As New Font("Arial", intFontSize)
Dim stringSize As SizeF
Measure String width
stringSize = grp.MeasureString(strStudentName, stringFont)
.
.
.
The page have totally no bugs and running well. But get error when upgrading asp.net 1.1 to asp.net2.0
Anyone know the solution? Thanks for all help.
Calvin
"Request for the permission of type System.Security.Permissions.UIPermission, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 failed."
The page have add reference to System.Windows.Forms.dll.
Below is part of my code:
Dim x As Windows.Forms.Form = New Windows.Forms.Form
Dim grp As Graphics = x.CreateGraphics()
Dim stringFont As New Font("Arial", intFontSize)
Dim stringSize As SizeF
Measure String width
stringSize = grp.MeasureString(strStudentName, stringFont)
.
.
.
The page have totally no bugs and running well. But get error when upgrading asp.net 1.1 to asp.net2.0
Anyone know the solution? Thanks for all help.
Calvin