473,387 Members | 1,528 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,387 software developers and data experts.

Shared Assembly

Hello Everyone,

I have created a shared assembly and I installed it in GAC -- now I want to
use this shared assembly in my Web project. Can anyone help me with this --
i tried adding a reference to my project and specifying it in web.config as
follows:

<runtime>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm:v1">
<dependentAssembly>
<assemblyIdentity name="WebSecurityBusinessObjects"
publicKeyToken="04a21a904cc5af93" culture="neutral" />
<probing privatePath="bin"/>
</dependentAssembly>
</assemblyBinding>
</runtime>

I am still getting security exception.

Thanks for all the help in advance.

Yatin Patel
Nov 19 '05 #1
8 954
Hi,

Try to include it under Referenece in your solution explorer using add
referenece.

Cheers,

Jerome. M

"Yatin Patel" wrote:
Hello Everyone,

I have created a shared assembly and I installed it in GAC -- now I want to
use this shared assembly in my Web project. Can anyone help me with this --
i tried adding a reference to my project and specifying it in web.config as
follows:

<runtime>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm:v1">
<dependentAssembly>
<assemblyIdentity name="WebSecurityBusinessObjects"
publicKeyToken="04a21a904cc5af93" culture="neutral" />
<probing privatePath="bin"/>
</dependentAssembly>
</assemblyBinding>
</runtime>

I am still getting security exception.

Thanks for all the help in advance.

Yatin Patel

Nov 19 '05 #2
Yatin what u can also do is to put the DLL files under ur BIN folder in
the wwwroot folder.
Hope it helps
Patrick
*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!
Nov 19 '05 #3
Hi,

Thanks for the reply but I have tried both ways:

1. by adding as a reference
2. by copying the dll under bin folder

no matter what i do, it still gives me the same error.

Yatin Patel
"Patrick Olurotimi Ige" wrote:
Yatin what u can also do is to put the DLL files under ur BIN folder in
the wwwroot folder.
Hope it helps
Patrick
*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!

Nov 19 '05 #4
Yatin try posting the exact error.
Patrick
*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!
Nov 19 '05 #5
Hi,

Sorry for the delay -- here is the exact error:

Security Exception
Description: The application attempted to perform an operation not allowed
by the security policy. To grant this application the required permission
please contact your system administrator or change the application's trust
level in the configuration file.

Exception Details: System.Security.SecurityException: Security error.

Regards,
Yatin Patel

"Patrick Olurotimi Ige" wrote:
Yatin try posting the exact error.
Patrick
*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!

Nov 19 '05 #6
Yatin,
But ur Error seems to be a Security issue!!
Do u have access to the right folder and the BIN folder ur application
is trying to use?
Try checking if your ASPNET acct has the necesary permissions.
Patrick
*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!
Nov 19 '05 #7
Patrick,

Yes, I tried giving the rights also but still its giving me the same error.

Regards,
Yatin Patel

"Patrick Olurotimi Ige" wrote:
Yatin,
But ur Error seems to be a Security issue!!
Do u have access to the right folder and the BIN folder ur application
is trying to use?
Try checking if your ASPNET acct has the necesary permissions.
Patrick
*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!

Nov 19 '05 #8
Hi Patrick,

I just found out that if I change the <trust> level to "Full" -- i am able
to access the assembly but if I change the <trust> level to "Medium" -- i get
the Securityexception error. As far as I know its not advisable to give Full
trust to the assemblies -- can you please let me know if I am doing anything
wrong here.

Regards,
Yatin Patel

"Yatin Patel" wrote:
Patrick,

Yes, I tried giving the rights also but still its giving me the same error.

Regards,
Yatin Patel

"Patrick Olurotimi Ige" wrote:
Yatin,
But ur Error seems to be a Security issue!!
Do u have access to the right folder and the BIN folder ur application
is trying to use?
Try checking if your ASPNET acct has the necesary permissions.
Patrick
*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!

Nov 19 '05 #9

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

Similar topics

3
by: Bill | last post by:
I created a shared assemble and dropped it into Windows\assembly. Browsing this directory shows that it is in there and the properties looks as expected. However, when I attempt to add this as a...
9
by: Invalidlastname | last post by:
Hi, We developed some assemblies which use EnterpriseServices queued components. In order to use EnterpriseServices, these assemblies need to be installed into GAC. I used the pre-build and...
4
by: Rubbrecht Philippe | last post by:
Hi there, I would like to develop an interface that when implemented in a class requires a number of shared properties or methods to be available. It seems a Shared Member can not be used as...
3
by: Bill | last post by:
I created a shared assemble and dropped it into Windows\assembly. Browsing this directory shows that it is in there and the properties looks as expected. However, when I attempt to add this as a...
2
by: Tony Johansson | last post by:
Hello! In directory c:\window\assembly(GAC) can you find a lot of global assembly names which is called shared assemblies. If I for example use ILDASM on a file called Accessibility which is...
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: 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: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
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?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
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,...
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.