Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
GotFocus like event for bars in a sysmenu popup?
Message
De
22/02/2002 14:21:25
 
 
À
22/02/2002 13:55:59
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire de menu & Menus
Divers
Thread ID:
00623560
Message ID:
00623864
Vues:
8
Hi Gregory,

Thanks for taking the time to see this challenge to the bitter end! Your snippet is cool - it works perfect for right mouse type context menus. It doesn't work for popups used in a VFP system menu, but at least I'm 50% of the way there.

In a worse case, I figure I could proprose a hybrid menu option to my client:

Fake menu pads (button) that activate their associated (hot-tracking event generating) popups.

This technique would eliminate a user's ability to use the left/right cursor keys to move between menu popups or the ability to point other menu pads and have their associated menu popup activate - but I'm sure both of these drawbacks could be programmed around.

Thanks again for your help and creativity!

Malcolm


>You are right in that the message part is only evaluated once.
>
>In addition, the following below only works for popups that are not activated via the menu. Once they get there, the game is over.
>
>There may, just may be a possibility, but I haven't found it.
>
>Menus, bars, pads and the like are strange animals in vfp
>
>Sorry, thought I had hit the jackpot
>
>
>*--------------------------------------------------------------------------
>procedure do_it()
>
>	local i, p
>	private MenuItem && not needed really, but shows possibilities
>	MenuItem = ''
>
>	p = sys(2015)
>	define popup (p) shortcut
>	for i = 1 to 10
>		define bar cntbar(p)+1 of (p) prompt str(i)
>		on bar cntbar(p) of (p) x=ShowIt(p, bar())
>	endfor
>
>	activate popup (p)
>	if( !empty(bar()) )	&& not escaped
>		?'MenuItem=', MenuItem
>	endif
>	release popup (p)
>
>endproc
>*--------------------------------------------------------------------------
>function	ShowIt(p, i)
>	MenuItem = 'Something ' + p + str(i)
>	*set help to aaa
>	*_screen.HelpContextId = 1000 + i
>	?? chr(7)
>	wait window nowait 'Menubar = ' + p + ' ' + str(i)
>	return 'active message ' + prmbar(p, i)
>
>endfunc
>*--------------------------------------------------------------------------
Malcolm Greene
Brooks-Durham
mgreene@bdurham.com
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform