The MS Platfrom SDK already has a sample for this: (sorry, in native C.)
C:\Program Files\Microsoft Visual Studio .NET 2003\Vc7\PlatformSDK\samples\winui\Shell\Fakemenu\. (if you installed VS.Net 2003 to the default folder)
Simple enough and the code is well documented.