Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
VMP Security Question
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Produits tierce partie
Divers
Thread ID:
00470602
Message ID:
00471268
Vues:
18
Hi Larry,

The only difference between my 2nd for..endfor and oApp.SetupGlobalToolbars() is that I send ".t." as the second parameter of the DoToolbar() method instead of ".f.".

I'm not sure where but there must be some other place during app startup that actually "shows" the global toolbar, because it is not done in oApp.SetupGlobalToolbars().



>One minor modification to this. I would recommend making a call to oApp.SetupGLobalToolbars(). The method does exactly what your second FOR...ENDFOR loop does and you don't have to reinvent it.
>
>FWIW, I agree this is a problem. If security is attached to global toolbars, then it should reinitialize the controls on user destroy.
>
>>I put the following code in my ctrxxapp.logout() method. Is this alright to do? Any forseeable pitfalls I might encounter doing this?
>>
>>
>>local lnCount
>>
>>if this.yBeforeLogout()
>>	** pea 01/31/2001
>>	** First delete all toolbars. The default behavior in dodefault is to hide all toolbars and
>>	** then when someone logs back in to show the toolbars. The problem with this is that I want
>>	** to put security on some of the options of the toolbar. In order to do this the toolbar must
>>	** be recreated because the security is checked in the init of each control.
>>	for lnCount = 1 to alen(this.iaGlobalToolbars,1)
>>  		if type("this.iaGlobalToolbars[lnCount,1]") = "C" and !isnull(this.iaGlobalToolbars[lnCount,1]) and !empty(this.iaGlobalToolbars[lnCount,1])
>>	    	oToolbars.DeleteInstance(this.iaGlobalToolbars[lnCount,1])
>>		endif
>>	endfor
>>
>>	dodefault()
>>
>>	** pea 01/31/2001
>>	** Then recreate the toolbars so that the different conrols' inits will fire and then check
>>	** security.
>>	for lnCount = 1 to alen(this.iaGlobalToolbars,1)
>>		if type("this.iaGlobalToolbars[lnCount,1]") = "C" and !isnull(this.iaGlobalToolbars[lnCount,1]) and !empty(this.iaGlobalToolbars[lnCount,1])
>>	    	oToolbars.DoToolbar(this.iaGlobalToolbars[lnCount,1],.t.,this.iaGlobalToolbars[lnCount,2])
>>		endif
>>	endfor
>>else
>>	nodefault
>>endif
>>
>>
>>Thanks,
>>Paul
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform