How to strong name an assembly which use interop.shell32?

N

Nicola Garone

Hi group
I developed a custom control wich use some shell functions, I've added
reference to shell32.dll, defined wrap for some interfacee and declared my
shell32's functions I need. Now it work fine in a test form, and load and
shows in a asp.net form. But when it need to use shell32 functions an
exception of type System.Security.Permissions.FileIOPermission is raised.

I know I have to grant permission to my UserControl, and I'd like to use
strong name for Condition Type. So I've generated a public-private key pair
using the command-line utility sn, and I added following line in
AssembyInfo.vb

<Assembly: AssemblyKeyFile("ClientUI.snk")>

but now I can't compile my project since it says

Impossibile creare l'assembly: L'assembly 'Interop.Shell32' al quale si fa
riferimento non ha un nome sicuro.
that is something like
Can't create assembly. Referenced assembly 'Interop.Shell32' doesn't have a
strong name.

the question is: how to solve sign with a strong name may control?

Thanks
Nicola Garone
 
N

Nicola Garone

Ok, I miss-typed the question and it gets uncomprensible, maybe this is the
reason why none answered?

So, my question is:

how to sign with a strong-name my control?
or
any alternatives?

thanks
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,989
Messages
2,570,207
Members
46,782
Latest member
ThomasGex

Latest Threads

Top