>>>>To create an object from a class definition: Look in the Help at
>>>CreateObject() and AddObject().
>>>>
>>>>SET CLASSLIB only tells VFP where to look for class definitions. It
>>>doesn't create any object.
>>>>
>>>>Vlad
>>
>>In my form class I emulate the behavior of what I've had in FPD, which
>>reacted on F3 and F4. In the form class init, I have
>>
>>on key label f3 _screen.activeform.f3f4(3)
>>on key label f4 _screen.activeform.f3f4(4)
>>
>
>This works only if you have a form on screen and if that form has an F3F4 method.
>
>In my opinion this shouldn't be in the form's Init, but in the main program/app class Init.
>
>I would do it like that:
>
>PROCEDURE F3F4
>PARAMETER lnKeyIndex
>IF TYPE("_SCREEN.ActiveForm.Name") = "C" and ;
> PEMSTATUS("_SCREEN.ActiveForm", "f3f4", 5)
> _SCREEN.ActiveForm.f3f4(lnKeyIndex)
>ENDIF
>RETURN
>
>And change your ON KEY to:
>
>ON KEY LABEL F3 DO F3F4(3)
>ON KEY LABEL F4 DO F3F4(4)
>
>Of course, the F3F4 proc may be a method in your app class.
>
>>Maybe I should move it to form's Activate, and also dismiss in any
>>proper place (it gets dismissed in Unload now)... which event fires if
>>the form's window is not the active window anymore?
>
>If you do it as I stated above, you don't need to worry about the dismiss of those settings anymore.
>
>Vlad
Very interesting.
Previous
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only