Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Changing Pad/Bar Prompt at run-time
Message
From
30/07/2004 06:16:47
Emanuele Bonin
EB Soluzioni Informatiche
Tezze S/B, Italy
 
 
To
29/07/2004 14:15:30
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00928219
Message ID:
00929510
Views:
18
Re-Hi Herman! 8)

Sorry if i'm appearing annoying but i want show to you the Candidate-Release code that i write and seems to found to change all caption in a menu al all submenus. I used the methods modify menu instead on setmenuiteminfo ... because this last one seems don't work with popup.

The Last My question regard the fact that this code work only for enabled caption do you know why ?

Do you know say me if the only way is ungrayed it modify it and regrayed it ?

Thanx in Advance for all your support to my hill-mind 8)

void LoopMenu(HMENU hMenu)
{

MENUITEMINFO MII;
int x, iCount;
char itemText[80];
char Stringa[200];
HMENU hSubMenu;

iCount = GetMenuItemCount( hMenu );
for (x=0; x < iCount; x++)
{
GetMenuString(hMenu, x, itemText, 80, MF_BYPOSITION);
sprintf( itemText, "Menu #&%d", x );
hSubMenu = GetSubMenu(hMenu, x);
ModifyMenu(hMenu, x, MF_BYPOSITION + MF_STRING, 0, itemText);
if(hSubMenu != NULL) LoopMenu(hSubMenu);
}
}

void EntryPoint(hWnd)
{
LoopMenu(GetMenu(hWnd));
DrawMenuBar((HWND) parm->p[0].val.ev_long);
}
bye, Emanuele!
In the beginning the Universe was created.
This has made a lot of people very angry and been widely regarded as a bad move.
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform