FiveTech Support Forums

FiveWin / Harbour / xBase community
Board index FiveWin for Harbour/xHarbour The word "Area" in a menu
Posts: 363
Joined: Wed Feb 15, 2006 02:06 PM
The word "Area" in a menu
Posted: Wed Nov 18, 2009 09:49 AM

Hi,

I have created a menu and want the option to say "Area Code Entry" with the A in area underlined, so i changed the text to read "&Area Code Entry" but when i look in the menu, the word Area has disapeared - it just shows " Code Entry" - any ideas?

Thanks in advance

Pete

Posts: 363
Joined: Wed Feb 15, 2006 02:06 PM
Re: The word "Area" in a menu
Posted: Wed Nov 18, 2009 10:32 AM

Update:

Modified my code so that the text for the menu is pulled from a dbf (i use this for multi language text) and it works fine - same text in the dbf as my hardcoded text but it works - Weird!

Posts: 10733
Joined: Sun Nov 19, 2006 05:22 AM
Re: The word "Area" in a menu
Posted: Wed Nov 18, 2009 11:20 AM

MENUITEM '&Area Code Entry' is working fine for me.

Regards



G. N. Rao.

Hyderabad, India
Posts: 4840
Joined: Fri Nov 18, 2005 04:52 PM
Re: The word "Area" in a menu
Posted: Wed Nov 18, 2009 12:11 PM

Pete,

Try looking at the preprocessor output. Maybe the preprocessor is changing it.

James

FWH 18.05/xHarbour 1.2.3/BCC7/Windows 10
Posts: 363
Joined: Wed Feb 15, 2006 02:06 PM
Re: The word "Area" in a menu
Posted: Wed Nov 18, 2009 01:29 PM

the ppo file looks like this:

MenuAddItem( "&Area Code",, .F.,, {|oMenuItem|msginfo("1")},,,,,,, .F.,,, .F. )
MenuAddItem( default_text("MENU", "CONDATA", "20"),, .F.,, {|oMenuItem|areacode_ent()},, "AREACODE",,,,, .F.,,, .F. )

The word area is missing from the first option, but is there when i use my data dictionary function. I'm not too worried about it really, as i shouldn't have any hardcoded text in my app.

I'm using xHarbour commercial with FW9.05 if this helps?

Posts: 10733
Joined: Sun Nov 19, 2006 05:22 AM
Re: The word "Area" in a menu
Posted: Fri Nov 20, 2009 06:26 PM

Such situation could arise when a variable ( public or private ) by name AREA exists in the scope with a value of null string( "" ).

In such a case "&Area Code" would be evaluated as "Code".

This can be verified by inserting a statement MsgInfo( Type( 'AREA' ) ), just before the code MENUITEM '&Area Code'

Regards



G. N. Rao.

Hyderabad, India

Continue the discussion