Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Wanet Telecoms Ltd on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

menu focus problem?

Status
Not open for further replies.

rkolva

Programmer
Jan 16, 2003
127
US
I'm getting un 'unknown member' error dialog when attempting to access a disabled menu.

The specific situation is this: I have two forms visible. Form1 is modal and 'As Top-Level Form'. Form2 is also modal but 'In Top-Level Form'. The custom menu is loaded in form1.init() and in my main prg I set Screen.Visible = .F. and SET SYSMENU TO and ON SELECTION MENU _MSYSMENU RETURN in an effort to keep the user from ever getting VFP's menu, this was also happening. The error occurs when form2 is active and the user attempts to access the menu on form1 and results in error dialogs stating the 3 buttons on form1 are 'unknown members'. I tried adding the line ON SELECTION MENU ALL RETURN to form2.init to keep the menu from getting focus but this doesn't appear to be working.

Does anybody have an idea of what is happening and how to avoid it?

Thanks,
Frustrated programmer

Code:
 
Never mind, It turned out that in my skip for conditions I was referencing the enabled status for buttons on form1 based on _screen.activeform and since form2 was active it caused the bomb.

Thanks anyway
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top