I am trying to get a menu working & am following how I did it last time (which worked in the same compiler) copying it exactly, the menu doesn't appear. I am using Dev-C++
Here is the function to create the menu:
Code:
HMENU CreateMainMenu(HWND hwnd) {
HMENU hMenu, hSubMenu;
hMenu = CreateMenu();
hSubMenu = CreatePopupMenu();
AppendMenu(hSubMenu, MF_STRING, WM_CLOSE, "E&xit\tAlt+F4");
AppendMenu(hSubMenu, MF_STRING |MF_POPUP, (UINT)hSubMenu, "&File");
hSubMenu = CreatePopupMenu();
AppendMenu(hSubMenu, MF_STRING | MF_UNCHECKED, 1002, "Show Postfix notation");
AppendMenu(hSubMenu, MF_STRING |MF_POPUP, (UINT)hSubMenu, "Functions");
SetMenu(hwnd, hMenu);
return hMenu;
}
& have called it just before the call to ShowWindow in WinMain().