Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
No such menu item
Message
 
 
À
23/05/2001 02:56:31
Cetin Basoz
Engineerica Inc.
Izmir, Turquie
Information générale
Forum:
Visual FoxPro
Catégorie:
Problèmes
Divers
Thread ID:
00510194
Message ID:
00510318
Vues:
20
>>Hi everybody,
>>
>>I'm getting error on this line of code:
>>* determine if program execution is currently suspended
>>suspended = not thisform.ehdp_isruntime ;
>> and not SKPBAR('_MSM_PROG', ;
>> _MPR_RESUM) && enablement of the VFP Program menu's
>>
>>The error is: no such menu item is defined. It's firstly caught by Error Handler, but then immediatelly shows VFP error. The question is: how to prevent it? Is this kind of error untrappable?
>>
>>Thanks in advance.
>
>Nadya,
>I don't know if it's trappable but I prefer to check existence then to rely on error checking :
>
lnBars = CntBar('_MSM_PROG')
>for ix = 1 to lnBars
> if (_MPR_RESUM) = GetBar('_MSM_PROG',ix)
>   ? 'Suspend exists and '+;
>     iif(SKPBAR('_MSM_PROG', _MPR_RESUM),'dis','en')+'abled.'
>   exit
> endif
>endfor
Cetin

Great, seems like exactly what is needed. Thanks a lot. lnBars returns 0 in our menu.
If it's not broken, fix it until it is.


My Blog
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform