LinkedIn

Wednesday, 19 November 2008

Workflow Public Key Tokens



Sharepoint workflow assemblies must be strongly named. The feature installation requires that you indicate the publick key token for the workflow assembly. There are a number of hoops one can jump through in order to obtain this public key. Here's some I've heard today:

* Drag the built assembly into the GAC, browse to the GAC, copy and paste the public key token from the explorer window;
* Drop to a command prompt, browse to the SDK/Bin directory, use the SN.EXE command line tool to retrieve the public key token, copy all the contents of the command window into notepad, find the public key entry, copy and paste into your xml file

or

You can be a lazy programmer like me and simply take the following steps:

* In Visual Studio
* Tools/External Tools
* Title: Get Public Key; Command: C:\Program Files\Microsoft Visual Studio 8\SDK\v2.0\Bin\sn.exe; Arguments: -Tp "$(TargetPath)"; use Output Window

Now you'll have an option on your Tools menu called "Get Public Key." Simply build your strongly named assembly, select Tools/Get Public Key and in the output window you'll be presented with the public key token, simply copy and paste... wala lazy programming shortcut.

this is from:
http://blogs.officezealot.com/jkremer/archive/2007/01/17/20075.aspx

RuSs