Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Can you put a variable on a MENU OPTION?
Message
From
14/05/1998 03:09:37
Mark Hall
Independent Developer & Voip Specialist
Keston, Kent, United Kingdom
 
 
To
13/05/1998 14:17:22
General information
Forum:
Visual FoxPro
Category:
Other
Miscellaneous
Thread ID:
00099099
Message ID:
00099331
Views:
19
>>My users want to see the _TALLY to the right of a MENU OPTION that says: ALL RECORDS FOR YOUR AREA. Can I add the _TALLY right beside the name?
>---
>My Question is : In the MENU, Can you put a reccount() on the same line as the menu name?

Yes, you can have whatever you want in the text for a menu option. But you have to redefine the menu item for each change in text. So you will probably have to call some code each time you expect _Tally to change.

Or I guess you could attach the code to a timer and have this refresh the menu after each set interval.

In the menu builder, set a PadName (e.g. PadRecords) and a BarNo (e.g. 1) for the item on the menu bar and the item on the drop down menu. Then issue a Define Bar command

DEFINE BAR 1 OF PadRecords PROMPT "ALL RECORDS FOR YOUR AREA" + LTRIM( STR( _Tally))

Alternatively use my great and wonderful Menu classes which are in the VCX section of the Files library. (but you'll still have to run some code for each change)
Regards
Mark

Microsoft VFP MCP
Menulib - OO Menus for VFP www.hidb.com/menulib
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform