PC Review


Reply
Thread Tools Rate Thread

Desperately seeking hMenu!

 
 
=?Utf-8?B?X2R0YXlsb3J1cw==?=
Guest
Posts: n/a
 
      31st Oct 2007
I can't find my hMenu anywhere! Can you help?

IntPtr hMenuBar = SHFindMenuBar(hWnd);
IntPtr hMenu = new IntPtr(SendMessage(hMenuBar, SHCMBM_GETSUBMENU, 0, 0));

hMenu is always 0 in the WM5 PocketPC emulator!

Also tried this, per the WM5 SDK topic "How to: Obtain a Handle to a Softkey
Menu":

IntPtr hMenu = new IntPtr(SendMessage(hMenuBar, SHCMBM_GETMENU, 0, 0));

Still 0.

Searched for the answer all over the net. Lots of people asking this
question. No answers.

Declarations:

const int WM_USER = 1024;
const int SHCMBM_GETSUBMENU = WM_USER + 401;
const int SHCMBM_GETMENU = WM_USER + 402;

[DllImport("aygshell.dll")]
internal static extern IntPtr SHFindMenuBar(IntPtr hwnd);

[DllImport("coredll.dll")]
internal static extern int SendMessage(IntPtr hWnd, uint Msg, uint wParam,
uint lParam);

 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Desperately Seeking Help! littlelegspinne Windows XP General 5 22nd Oct 2005 02:05 AM
Desperately seeking some help! (Please) Peter Long Microsoft Excel Programming 7 1st Nov 2004 09:07 PM
Desperately seeking some help here! <PLEASE> Peter Long Microsoft Excel Discussion 1 29th Oct 2004 11:26 AM
Desperately seeking HELP *** sha Microsoft Access Reports 3 20th May 2004 03:31 PM
Desperately Seeking MCT Charles Windows XP Music 0 9th Sep 2003 03:56 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 07:10 PM.