Retro video games delivered to your door every month!
Click above to get retro games delivered to your door ever month!
X-Hacker.org- dBsee 4.6 - The Library - <b>attach ... function</b> dfctrl.ch http://www.X-Hacker.org [<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
ATTACH ... FUNCTION                                             DFCTRL.CH   
Makes a new control of type FUNCTION
------------------------------------------------------------------------------
Syntax:

     ATTACH <cId> TO <aParent> FUNCTION <uVar> ;
                  AT <nTop>, <nLeft>, <nBottom>, <nRight>;
                  [PAGE <nPage>] ;
                  [PICTURESAY <cPicSay>] ;
                  [PROMPT <cPrompt>] ;
                  [PROMPTAT <nPRow>, <nPCol>] ;
                  [BOX <nBox>] ;
                  [COLOR <aCol>] ;
                  [DISPLAYIF <uDiIf>];
                  [<Rti:REALTIME>] ;
                  [BEFORE <uBefore>] ;
                  [COMPUTEDEXP <uCmpExp>] ;
                  [COMPUTEDGRP <uCmpGrp>] ;
                  [REFRESHID <cRID>] ;

Parameters:

     <cId>      Shows the name of the control 
     <aParent>  Item of objects form in which the controls are added 
     <uVar>     Name of the variable 
     AT <nTop>, <nLeft>, <nBottom>, <nRight> Coordinates where is the
                control FUNCTION on the object Coordinates are of the
                objects. Coordinates
     <nBottom> end <nRight> are used when ATTACH FUNCTION single out a
                control of Lookup of type MEMO
     PAGE <nPage> Number of page where is the control If nPage = 0 the
                control is available on all pages of management
     PICTURESAY <cPicSay> Picture used for show date 
     PROMPT <cPrompt> Messagge associated at the control FUNCTION 
     PROMPTAT <nPRow>, <nPCol> Coordinates where is the PROMPT of control
                FUNCTION
     BOX <nBox> Type Box. If the value of nBox is 1 BOX is of type normal,
                2 type button, 3 type filled. Parameter <nBox> is used
                only when the control FUNCTION single out a control Lookup
                of type MEMO. <nBox> show the type of Box that surround the
                field MEMO
     COLOR <aCol> Array where there are attributes of color Clipper used
                for link at the control the specific color
     DISPLAYIF <uDiIf> Conditional Display. the control in shown on the
                objects if the expression in <uDiIf> is True
     <REALTIME> Attribute of real time. If there is parameter, at the
                control is associated the attribute of real time.
     BEFORE <uBefore> Code Block that is executed before control 
     COMPUTEDEXP <uCmpExp> Expression of evaluation for the field
                calculated
     COMPUTEDGRP <uCmpGrp> ID of CONTROL of typeo GET that must call the
                refresh of this CONTROL
     REFRESHID <cRID> Show the  groups of refresh which contain the control

Description:

     The name control FUNCTION is of the control that characterizes
     expression or Lookup.
     
     For manage this CONTROL from program is necessary to use the function
     tbCTRLArr().This function will give the array that forms the CONTROL.
     With modification of this array is possible change during RUN-TIME
     characteristic of the CONTROL.

Example:

     Example 1 :
     
     Value of item of the array when the CONTROL
     is of type BOX :
     
     
     LOCAL aCTRL := tbCTRLArr( oWin, "FUN0001" )
     
     aCTRL[FORM_CTRL_TYP      ] // Type CONTROL
     aCTRL[FORM_CTRL_ID       ] // ID of control
     aCTRL[FORM_CTRL_RID      ] // Refresh ID of CONTROL
     aCTRL[FORM_CTRL_PAGE     ] // Page of CONTROL
     aCTRL[FORM_CTRL_STABLE   ] // Flag for stable fhe CONTROL
     aCTRL[FORM_CTRL_DISPLAYIF] // CodeBlock of "Showing only if ..."
     
     aCTRL[FORM_FUN_VAR     ] // Variable that is shown
     aCTRL[FORM_FUN_TOP     ] // Coordinates of CONTROL
     aCTRL[FORM_FUN_LEFT    ] //
     aCTRL[FORM_FUN_BOTTOM  ] //
     aCTRL[FORM_FUN_RIGHT   ] //
     aCTRL[FORM_FUN_PICTURE ] // Picture of visualization
     aCTRL[FORM_FUN_PROMPT  ] // Value of the PROMPT
     aCTRL[FORM_FUN_PROW    ] // Coordinates of the Prompt
     aCTRL[FORM_FUN_PCOL    ] //
     aCTRL[FORM_FUN_BOX     ] // Type of box if there is border
     aCTRL[FORM_FUN_CLRID   ] // Array of colors
     aCTRL[FORM_FUN_BEFORE  ] // Function executed before display
     aCTRL[FORM_FUN_REALTIME] // Attivation of control in REALTIME
     
     Example 2 :
     
     #include "DFCTRL.CH"
     
     ATTACH "exp066" TO oWin:W_CONTROL FUNCTION Time()
       AT  18, 60, 0,0                ; // Position
       PAGE  0                        ; // Page
       COLOR {NIL,NIL,"G+/G",NIL,NIL} ; // Array of colors
       PICTURESAY "9999"              ; // Picture say
       DISPLAYIF {||.T.}                // Condition


Online resources provided by: http://www.X-Hacker.org --- NG 2 HTML conversion by Dave Pearson