Hi
I have to add third party ocx on web page. For that we developed windows control librray and add ocx on that. After creating dll i added that dll in Web page by object tag. Weh i try to load page WebControlLibrr ay control not get open on the page. If i disable security policy by caspol -s off and try to load page it opens the webControlLibrr ay object. With security enable i get the following errror
URL: http://pc-p43053/WebSite/CustomControl.d ll
Zone: 2
Assembly Name: CustomControl.d ll
Type Name: CustomControl.U serControl1
----- Thrown Exception -----
System.Security .SecurityExcept ion: Request for the permission of type 'System.Net.Web Permission, System, Version=2.0.0.0 , Culture=neutral , PublicKeyToken= b77a5c561934e08 9' failed.
at System.Security .CodeAccessSecu rityEngine.Chec k(Object demand, StackCrawlMark& stackMark, Boolean isPermSet)
at System.Security .CodeAccessPerm ission.Demand()
at System.Reflecti on.Assembly.Int ernalLoad(Assem blyName assemblyRef, Evidence assemblySecurit y, StackCrawlMark& stackMark, Boolean forIntrospectio n)
at System.Reflecti on.Assembly.Int ernalLoadFrom(S tring assemblyFile, Evidence securityEvidenc e, Byte[] hashValue, AssemblyHashAlg orithm hashAlgorithm, Boolean forIntrospectio n, StackCrawlMark& stackMark)
at System.Reflecti on.Assembly.Loa dFrom(String assemblyFile, Evidence securityEvidenc e, Byte[] hashValue, AssemblyHashAlg orithm hashAlgorithm)
at System.Activato r.CreateComInst anceFrom(String assemblyName, String typeName, Byte[] hashValue, AssemblyHashAlg orithm hashAlgorithm)
at System.AppDomai n.CreateComInst anceFrom(String assemblyFile, String typeName, Byte[] hashValue, AssemblyHashAlg orithm hashAlgorithm)
at System.AppDomai n.CreateComInst anceFrom(String assemblyFile, String typeName, Byte[] hashValue, AssemblyHashAlg orithm hashAlgorithm)
at Microsoft.IE.Se cureFactory.Cre ateInstanceWith Security(Int32 dwFlag, Int32 dwZone, String pURL, String uniqueIdString, String link, String licenses)
The action that failed was:
Demand
The type of the first permission that failed was:
System.Net.WebP ermission
The first permission that failed was:
The demand was for:
The granted set of the failing assembly was:
The assembly or AppDomain that failed was:
mscorlib, Version=2.0.0.0 , Culture=neutral , PublicKeyToken= b77a5c561934e08 9
0 823 Sign in to post your reply or Sign up for a free account.
Similar topics |
by: Tim |
last post by:
I have block of code adding values to dropdown list under
if (!Page.IsPostBack)
{
adding items
}
else
{
refreshing data
}
|
by: DotNetJunky |
last post by:
I have built a control that runs an on-line help system. Depending on the
category you selected via dropdownlist, it goes out and gets the child
subcategories, and if there are any, adds a new dropdownlist to the screen
for selection. This continues until there are no children, and then it
checks for a help article list based on that last selection and displays
actual articles for display.
Adding the controls and getting everything...
|
by: Jim Heavey |
last post by:
Trying to figure out the technique which should be used
to add rows to a datagrid. I am thinking that I would
want an "Add" button on the footer, but I am not quite
sure how to do that. Is that the best method? Do you
have a sample of how to do this?
|
by: Jeremy Ames |
last post by:
I have run into a major road block with my page development projects. I am
trying to add a literal control to my asp.net page and I got an error
stating that the control could not be added because of code blocks (<% %>)
on the page. Most of these blocks can be handled by adding a label control
to the form so it is not that big of deal, but one of the things being
posted is the page title. I am not sure how I can access that from the code...
|
by: seanmayhew |
last post by:
I have a form page that that while editing saves the data to an xml doc
before submitting to db. On each page
unload it saves the xmldoc as the user can add multiple items to the
company like product types etc. So for
instance Im adding a fruit company while adding a fruit company I allow
the user to add types of fruit they
carry and display it dynamically using an <asp:table> with image
| |
by: Ankit Aneja |
last post by:
I have a strange situation and I have no idea how to solve this.
Its a Recruitment Search Page,in the Admin Page, for every button click
event the Admin Person has to create a checkbox on the users page. So
whenever the Admin person comes to know about the new category in the market
he will be adding as different Sub-Categories for example ABAP, BDC
etc..etc.. on every click event as Checkboxes. And these
controls(checkboxes) should remain...
|
by: Bart Van Hemelen |
last post by:
I'm working on a project where the user of a site will receive custom
content, depending on a set of parameters. The content will all be
contained in UserControls (.ascx), that will be used as webparts on a
page.
We need to add the webparts dynamically to the site, depending on the
status of the user: this involves a personalisation of a travel
website, so a user can be "before" a trip, "during" a trip and "after"
a trip, and depending...
|
by: Ben Dewey |
last post by:
Okay, so I have a base Page class called ArticlesPageBase. This base class
has reads in an overridable ArticleId and Loads the data into a Panel object
in the ContentPlaceHolder of the Master.
The article that it loads from the Database is a xml field that contains
html code for the article. I added some custom html to the database article
called <question id="22" />
When the article contains inline questions are parse out the start...
|
by: ChrisCicc |
last post by:
Hi All, I got a real doozy here. I have read hundreds upon hundreds of forum posts and found numerous others who have replicated this problem, but have yet to find a solution. Through testing I have been able to find the cause of the problem, and will describe it here first textually and then through a code example.
The purpose of what I am trying to do is to create a postback-free web application through the use of ASP.net AJAX UpdatePanels...
|
by: Jason |
last post by:
Hello,
I am trying to utilitze the AJAX Control toolkit in my asp.net project. I
have added a reference to AjaxControlToolkit.dll, and in my page, added
these lines of code:
<ajaxToolkit:ToolkitScriptManager runat="Server"
EnableScriptGlobalization="true" EnableScriptLocalization="true"
ID="ScriptManager1" />
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look !
Part I. Meaning of...
| |
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it.
First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
|
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed.
This is as boiled down as I can make it.
Here is my compilation command:
g++-12 -std=c++20 -Wnarrowing bit_field.cpp
Here is the code in...
|
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth.
The Art of Business Website Design
Your website is...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules.
He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms.
Adolph will...
|
by: TSSRALBI |
last post by:
Hello
I'm a network technician in training and I need your help.
I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs.
The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols.
I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
|
by: 6302768590 |
last post by:
Hai team
i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
| |
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
|
by: bsmnconsultancy |
last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...
| |