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

Discussion in 'ASP .Net Building Controls' started by Nicola Garone, Apr 15, 2004.

  1. 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
     
    Nicola Garone, Apr 15, 2004
    #1
    1. Advertising

  2. 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

    "Nicola Garone" <> ha scritto nel messaggio
    news:...
    > 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
    >
    >
     
    Nicola Garone, Apr 19, 2004
    #2
    1. Advertising

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

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. =?Utf-8?B?QW5uaWU=?=

    How to remove the key from a strong name assembly?

    =?Utf-8?B?QW5uaWU=?=, Jan 28, 2004, in forum: ASP .Net
    Replies:
    3
    Views:
    8,565
    =?Utf-8?B?QW5uaWU=?=
    Jan 28, 2004
  2. Tim
    Replies:
    1
    Views:
    453
    Jack Klein
    Jan 8, 2004
  3. namekuseijin

    Re: "Strong typing vs. strong testing"

    namekuseijin, Sep 27, 2010, in forum: C Programming
    Replies:
    214
    Views:
    3,407
    Nick Keighley
    Oct 17, 2010
  4. namekuseijin

    Re: "Strong typing vs. strong testing"

    namekuseijin, Sep 27, 2010, in forum: Python
    Replies:
    229
    Views:
    3,509
    Gregory Ewing
    Oct 29, 2010
  5. Elmo Watson
    Replies:
    0
    Views:
    573
    Elmo Watson
    Nov 9, 2007
Loading...

Share This Page