473,386 Members | 1,602 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

User Control Problem

I have created a windows user control library and all the controls have been
tested and work perfectly.

Next i built the project as a release version and stored the final copies
onto the network.

I now want to develop a totally seperate application that references the
control library, so a create a new project and reference in the .dll file
from the network. Next i add the controls to the My User Controls section of
the toolbox (by adding a reference to the same networtk file) .

When I drag an item onto a form I get the following error

An error occured while trying to create an instance of [contol name]. The
exception was "Request for the permission of type
System.Security.Permissions.FileIOPermission, mscorlib, version ........
failed"

Does anyone have any ideas... have I missed a step?

Thanks in advance
Nov 21 '05 #1
3 1039
Have you trusted the assembly ?

Windows Control Panel, Administration Tools, Microsoft .NET 1.1 Wizards

--

OHM ( Terry Burns )
. . . One-Handed-Man . . .
If U Need My Email ,Ask Me

Time flies when you don't know what you're doing

"hplloyd" <hp*****@discussions.microsoft.com> wrote in message
news:E0**********************************@microsof t.com...
I have created a windows user control library and all the controls have been tested and work perfectly.

Next i built the project as a release version and stored the final copies
onto the network.

I now want to develop a totally seperate application that references the
control library, so a create a new project and reference in the .dll file
from the network. Next i add the controls to the My User Controls section of the toolbox (by adding a reference to the same networtk file) .

When I drag an item onto a form I get the following error

An error occured while trying to create an instance of [contol name]. The
exception was "Request for the permission of type
System.Security.Permissions.FileIOPermission, mscorlib, version ........
failed"

Does anyone have any ideas... have I missed a step?

Thanks in advance

Nov 21 '05 #2
Sorry... ignore that... the problem was that I had not referenced in another
user.dll that the control library that I was using relied upon

Thanks anyway

"hplloyd" wrote:
I have created a windows user control library and all the controls have been
tested and work perfectly.

Next i built the project as a release version and stored the final copies
onto the network.

I now want to develop a totally seperate application that references the
control library, so a create a new project and reference in the .dll file
from the network. Next i add the controls to the My User Controls section of
the toolbox (by adding a reference to the same networtk file) .

When I drag an item onto a form I get the following error

An error occured while trying to create an instance of [contol name]. The
exception was "Request for the permission of type
System.Security.Permissions.FileIOPermission, mscorlib, version ........
failed"

Does anyone have any ideas... have I missed a step?

Thanks in advance

Nov 21 '05 #3
* "=?Utf-8?B?aHBsbG95ZA==?=" <hp*****@discussions.microsoft.com> scripsit:
Next i built the project as a release version and stored the final copies
onto the network.

I now want to develop a totally seperate application that references the
control library, so a create a new project and reference in the .dll file
from the network. Next i add the controls to the My User Controls section of
the toolbox (by adding a reference to the same networtk file) .

When I drag an item onto a form I get the following error

An error occured while trying to create an instance of [contol name]. The
exception was "Request for the permission of type
System.Security.Permissions.FileIOPermission, mscorlib, version ........
failed"


You will have to trust the location the assembly (control library) is
placed on:

<URL:http://www.google.de/groups?selm=eq8eIoh8CHA.3208%40TK2MSFTNGP11.phx.gb l>

..NET Framework Enterprise Security Policy Administration and Deployment
<URL:http://msdn.microsoft.com/library/en-us/dnnetsec/html/entsecpoladmin.asp>

Chapter 8 - Code Access Security in Practice
<URL:http://msdn.microsoft.com/library/en-us/dnnetsec/html/THCMCh08.asp>

--
M S Herfried K. Wagner
M V P <URL:http://dotnet.mvps.org/>
V B <URL:http://dotnet.mvps.org/dotnet/faqs/>
Nov 21 '05 #4

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

Similar topics

1
by: Earl Teigrob | last post by:
Background: When I create a ASP.NET control (User or custom), it often requires security to be set for certain functionality with the control. For example, a news release user control that is...
2
by: Sam Kuehn | last post by:
There has been a lot of articles on how to load user controls at runtime in the Init() method. UserControl myControl = (UserControl)LoadControl(stringControl); I add the control in the Init()...
6
by: Steve Booth | last post by:
I have a web form with a button and a placeholder, the button adds a user control to the placeholder (and removes any existing controls). The user control contains a single button. I have done all...
4
by: thomson | last post by:
Hi all, i do have a user control with 4 buttons, and all the events are firing properly, My problem is that i need to right an event handler in the user control, which gets fired after a...
8
by: David Lozzi | last post by:
Howdy, I have a user control that is a report to display data. On the page the control is inserted in, I have filter options to filter the report. When I try to do something like this, nothing...
5
by: Segfahlt | last post by:
I need a little help here please. I have 2 win forms user controls in 2 different projects that I'm hosting in 2 different virtual directories. The controls have been test and operate okay in...
4
by: Tony Johansson | last post by:
Hello! I have one solution file that consist of three project. One project that build the exe file called A One project that build a user control dll. Here we have a class called B One project...
5
by: Tony Johansson | last post by:
Hello! I have one solution file that consist of three project. One project that build the exe file called A One project that build a user control dll. Here we have a class called B One project...
5
by: tony | last post by:
Hello! This is a rather long mail but it's a very interesting one. I hope you read it. I have tried several times to get an answer to this mail but I have not get any answer saying something...
3
by: jonathan.beckett | last post by:
I have been experimenting with placing user controls (using Windows Forms controls) into an ASP.NET webpage - and am completely stuck. I can get a blank user control to work, but nothing beyond...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
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...
0
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,...

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.