Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Adding a new Pad to Top Level Form Menu
Message
 
 
À
Tous
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire de menu & Menus
Titre:
Adding a new Pad to Top Level Form Menu
Divers
Thread ID:
00635601
Message ID:
00635601
Vues:
58
I have no problems getting my menu running in a top level form. The probelm I have is getting a new menu pad inserted before an existing pad on this menu. I tried creating this with the menu designer but it failed even when I call this menu from a method in the TLF using do (tcMenuName) with This, This.Name

The problem is it replaces my TLF main menu. I checked the box in the General Options for Top Level form and the option for Before and gave the name of the pad to insert this before. Before I migrated to using a top level form, all the code I needed to do this was
local lnKount, i, lcPad
lnKount = cntpad("_msysmenu")
for i = 1 to lnKount
	lcPad = getpad("_msysmenu", i)
	if upper(lcPad) = "_PERMITGEN"
		return
	endif
endfor

DEFINE PAD _PermitGen OF _MSYSMENU BEFORE _Help ;
	PROMPT "\<Permits" COLOR SCHEME 3 KEY ALT+P, ""
ON PAD _PermitGen OF _MSYSMENU ACTIVATE POPUP PermitGen

DEFINE POPUP PermitGen MARGIN RELATIVE SHADOW COLOR SCHEME 4

DEFINE BAR 1 OF PermitGen PROMPT "Cover Letter"
DEFINE BAR 2 OF PermitGen PROMPT "Fact Sheet"
DEFINE BAR 3 OF PermitGen PROMPT "Permit"

ON SELECTION BAR 1 OF PermitGen oApp.DoForm("CoverLetter", "frmCoverLetter")
ON SELECTION BAR 2 OF PermitGen oApp.DoForm("FactSheet", "frmFactSheet")
ON SELECTION BAR 3 OF PermitGen oApp.DoForm("PermitDoc", "frmPermitDoc")

RETURN
Any enlightenment will be most appreciated. TIA!
Mark McCasland
Midlothian, TX USA
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform