473,732 Members | 2,217 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

a System.Security .SecurityExcept *ion trying to consume .net event in JScript code

Hi all,
I've got this problem.

I've to implemente a solution like the example in
http://support.microsoft.com/default...b;EN-US;313891, but I
can't configure correctly the example.
Every time I click on the textBox a System.Security .SecurityExcept ion
is raised.
At the end of MSDN article it's reported that I've to use .NET
Framework Configuration tool to grant the assembly the individual
permissione that are required, but I don't know how I can do it.

I've also tried to disabled policy checking with command caspol -s off
but I've always the same problem
Any ideas ?
The complete stacktrace of my System.Security .SecurityExcept ion is the

following:
-----------------------
See the end of this message for details on invoking
just-in-time (JIT) debugging instead of this dialog box.
************** Exception Text **************
System.Security .SecurityExcept ion: Request for the permission of type
'System.Securit y.Permissions.S ecurityPermissi on, mscorlib,
Version=2.0.0.0 , Culture=neutral , PublicKeyToken= b77a5c561934e08 9'
failed.
at ActiveXSourcing .ControlEvents. ClickEvent(Int3 2 x, Int32 y)
at ActiveXSourcing .MyWindowContro l.ClickHandler( Object sender,
EventArgs e)
at System.Windows. Forms.Control.O nClick(EventArg s e)
at System.Windows. Forms.TextBoxBa se.OnMouseUp(Mo useEventArgs mevent)

at System.Windows. Forms.Control.W mMouseUp(Messag e& m, MouseButtons
button, Int32 clicks)
at System.Windows. Forms.Control.W ndProc(Message& m)
at System.Windows. Forms.TextBoxBa se.WndProc(Mess age& m)
at System.Windows. Forms.TextBox.W ndProc(Message& m)
at
System.Windows. Forms.Control.C ontrolNativeWin dow.OnMessage(M essage& m)
at System.Windows. Forms.Control.C ontrolNativeWin dow.WndProc(Mes sage&

m)
at System.Windows. Forms.NativeWin dow.Callback(In tPtr hWnd, Int32
msg, IntPtr wparam, IntPtr lparam)
The action that failed was:
Demand
The type of the first permission that failed was:
System.Security .Permissions.Se curityPermissio n
The Zone of the assembly that failed was:
Intranet
************** Loaded Assemblies **************
mscorlib
Assembly Version: 2.0.0.0
Win32 Version: 2.0.50727.42 (RTM.050727-4200)
CodeBase:
file:///C:/WINDOWS/Microsoft.NET/Framework/v2.0.50727/mscorlib.dll
----------------------------------------
System
Assembly Version: 2.0.0.0
Win32 Version: 2.0.50727.42 (RTM.050727-4200)
CodeBase:
file:///C:/WINDOWS/assembly/GAC_MSIL/System/2.0.0.0__b77a5c 561934e089/Syste*m.dll

----------------------------------------
TestDll
Assembly Version: 1.0.2389.34599
Win32 Version: n/a
CodeBase: http://localhost/TestDll/TestDll.DLL
----------------------------------------
System.Windows. Forms
Assembly Version: 2.0.0.0
Win32 Version: 2.0.50727.42 (RTM.050727-4200)
CodeBase:
file:///C:/WINDOWS/assembly/GAC_MSIL/System.Windows. Forms/2.0.0.0__b77a5c 56*1934e089/System.Windows. Forms.dll

----------------------------------------
System.Drawing
Assembly Version: 2.0.0.0
Win32 Version: 2.0.50727.42 (RTM.050727-4200)
CodeBase:
file:///C:/WINDOWS/assembly/GAC_MSIL/System.Drawing/2.0.0.0__b03f5f 7f11d50a*3a/System.Drawing. dll

----------------------------------------
Accessibility
Assembly Version: 2.0.0.0
Win32 Version: 2.0.50727.42 (RTM.050727-4200)
CodeBase:
file:///C:/WINDOWS/assembly/GAC_MSIL/Accessibility/2.0.0.0__b03f5f 7f11d50a3*a/Accessibility.d ll

----------------------------------------
Microsoft.mshtm l
Assembly Version: 7.0.3300.0
Win32 Version: 7.0.3300.0
CodeBase:
file:///C:/WINDOWS/assembly/GAC/Microsoft.mshtm l/7.0.3300.0__b03 f5f7f11d50a*3a/Microsoft.mshtm l.dll

----------------------------------------
************** JIT Debugging **************
To enable just-in-time (JIT) debugging, the .config file for this
application or computer (machine.config ) must have the
jitDebugging value set in the system.windows. forms section.
The application must also be compiled with debugging
enabled.
For example:
<configuratio n>
<system.windows .forms jitDebugging="t rue" />
</configuration>
When JIT debugging is enabled, any unhandled exception
will be sent to the JIT debugger registered on the computer
rather than be handled by this dialog box

Jul 19 '06 #1
0 1429

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
1415
by: Htat | last post by:
When I write a program for event Log to check how many pages printed in my organization, I check print Event in System Event. My program works fine but when someone prints 2 or more copies in winword of the same document, the print event log shows only one page printed. See below. Event log ================ Document 18, Microsoft Word - Compliment Slips.doc owned by RayH was printed
1
1999
by: josh | last post by:
Hi, I have several independent, system components that write audit events to a database locally via ODBC and remotely via TCP, and I have a requirement to audit when the database is available for modification. First, does SQL Server have a concept of starting/stopping specific database instances? Or does my database instance "stop" only when the NT service MSSQLSERVER stops? Second, Oracle has system event triggers, e.g. AFTER...
1
1550
by: foekall | last post by:
Dear all...... I want to write security code with PHP plz help me........
5
7157
by: eitangabay | last post by:
Hi all . I want to know when new process has added\loaded, i looked for system event but i could not find any. Is there any way to do it ? I'm writing in c#.NET. (Process Added meand that new process added to the task manager)
8
2473
by: =?Utf-8?B?U3RldmVU?= | last post by:
Under Vista, my program, when reading the system event log, will not show the message saying I don't have the right permission. All I wisht to do is read the event log and show the error messages. Do I need to somehow use EventLogPermission? I can't find any examples of how to use it properly. Does someone know how to correctly read the system event log messages? -- ----------- Thanks, Steve
1
1229
by: deba2learn | last post by:
Hi, Can anyone tell me how I can able to catch system event like delete, rename etc through .NET. This means suppose someone want to delete a file from file system and press Shift + Delete. I want this command (Delete) should be caught by application designed by me. So what I do want to know is what are the API / Library that I need to use for the same in .NET. Your suggestion is truly valuable to me.
2
1900
by: Akkad | last post by:
Hi everyone ..... i am designing a web site and on the login page i want to embeed a security code but i don't know from where to install the library or even the function who create the picture of the security code , so plz help coz it is so urgent and i will be thankful akkad
13
1526
by: oruccim | last post by:
hii my friends; I want to create picture of security code.can i do it ? if yes,how , which module will help me? have you got a example that can create a picture whit my name pls help me thansk oruc
1
1564
by: Ahmad | last post by:
Hi, I am developing a desktop based application that will pull data from a site for a specific keyword. The site I am using is http://freekeywords.wordtracker.com/ Now to search a keyword like "Development" the constructed URL will be:
0
8946
marktang
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...
0
9447
Oralloy
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...
0
9307
jinu1996
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...
1
9235
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
9181
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
4550
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...
0
4809
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
3261
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
3
2180
bsmnconsultancy
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...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.