Click here to Skip to main content
15,886,774 members
Please Sign up or sign in to vote.
5.00/5 (1 vote)
Hi,

I have a Dll file. I want to create strong key name using this dll file.
how can do that.

I have tried some code using sn -k command on cmd prompt.
C:\Windows\assembly> sn -k "D:\WebPratice\Edraw\Edraw\bin\Edraw.snk"

but i got below message.....My dll file is Edraw.dll
'sn' is not recongized as an internal or external command,operable program or batch file

Please any one have a answer.......plz help.

Thanks & Regards
Mukesh
Posted

Hello Mukesh,

you cannot run sn command in any command window.. the environment variables needs to be set.

Run the command in Visual studio 20xx command prompt. you will find it in start - programs - visual studio 20xx - visual studio tools - Visual studio 20xx command prompt.

Thanks,
Hemant

Edit:
you can also add a strong key to a project's dll. for instance if Edraw is your project in VS 2008 and its generating Edraw.dll then you can goto project properties (i.e. right click on project-> properties) then "Signing" tab, and after that check "Sign the assembly" check box.

A drop down box below "Sign the assembly" checkbox will get enable "choose a strong name key file" select New in it will ask you for file name pass Edraw.snk to it. if you want the file to be password protected pass the password information to the same dialog box otherwise uncheck the "protect my key file with a password" checkbox.

you are done.

Thanks,
Hemant
 
Share this answer
 
v3
Comments
mukesh_panth 30-Apr-11 3:52am    
Hi Hemant,
Thank for reply,

In order to your steps i have created strong key.
Hemant I have little issue. I have created a web application using Edraw component.web application is running successfully in my local host. but when i am accessing from the another pc my web application is run but Edraw component is not displaying.Is edraw component register in ther another pc.
Any suggestion... i will appreciate to you...

Thanks & Regards
Mukesh Panth
Hemant__Sharma 30-Apr-11 4:17am    
Hello Mukesh,
Edraw has provided a helpful documentation, i hope you have covered all the points stated

http://www.edrawsoft.com/docs/excelvieweruserguide.pdf

page No. 37

Thanks,
Hemant
Hemant__Sharma 2-May-11 0:23am    
Did the above answer helped?
The VS tools aren't normally included in the command path, you must include the VS2008 binaries path in your command prompt.
The easiest way to do this is to:
1) Start button
2) All Programs
3) Microsoft Visual Studio 2008...Visual Studio Tools...Visual Studio 2008 Command Prompt
The tools will then be pathed, and you can proceed as normal.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900