วันจันทร์ที่ 12 มกราคม พ.ศ. 2552

Enum to String and String to Enum

Enum to String
Enum.GetName( typeof(EnumType), mode)

String to Enum
(EnumType)Enum.Parse(typeof(EnumType);, EnumValue, true);

วันศุกร์ที่ 9 มกราคม พ.ศ. 2552

Generate key file (*.snk) by sn.exe

Go to Visual Studio Tool For "Visual Studio 2xxx Command Prompt
and type "sn.exe -k xxxx.snk"
Example

sn.exe -k c:\myKeyFile.snk

this will generate myKeyFile.snk to C:\