For shortcuts I don't code each one directly. I wait until the later 
like this:

LOCAL nBar  
nBar = 0  
DEFINE POPUP myMenu MARGIN RELATIVE SHORTCUT  
DEFINE BAR 1 OF myMenu PROMPT "Test 1"  
DEFINE BAR 2 OF myMenu PROMPT "Test 2"  
ON SELECTION POPUP myMenu nBar = BAR()  
ACTIVATE POPUP myMenu  
RELEASE POPUPS myMenu  
IF nBar > 0  
    MESSAGEBOX("You selected bar #" + TRANSFORM(nBar))  
ENDIF  

hth,
Tracy


MB Software Solutions, LLC wrote:
> I've not written shortcut menus into my apps before, but was going to 
> this time for a small one.  Apparently, I can't do the following:
>
> On Selection Bar 1 of MyPopup thisform.EditTeacher()
>
> When the ACTIVATE POPUP command fires, it errors with "THISFORM can only 
> be used within a method."
>
> Must I resort to old fashioned PRGs to get this done?  I just want to 
> run this simple code in the EditTeacher method:
>
> LOCAL loFrm as Form, llRequery as Logical
> DO FORM .\forms\frmEditTeacher NAME loFrm TO llRequery
> IF llRequery THEN
>       this.RequeryData()
> ENDIF
>
> Ideas?  tia!
>
>   

_______________________________________________
Post Messages to: [email protected]
Subscription Maintenance: http://leafe.com/mailman/listinfo/profox
OT-free version of this list: http://leafe.com/mailman/listinfo/profoxtech
Searchable Archive: http://leafe.com/archives/search/profox
This message: 
http://leafe.com/archives/byMID/profox/[email protected]
** All postings, unless explicitly stated otherwise, are the opinions of the 
author, and do not constitute legal or medical advice. This statement is added 
to the messages for those lawyers who are too stupid to see the obvious.

Reply via email to