Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Abstract reference to buffer field contents?
Message
De
21/12/1999 19:02:26
 
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00306762
Message ID:
00307019
Vues:
38
Hi Dan,

>How do you get the ActiveControl from a grid?
LOCAL loActiveControl, lnColumn, loColumn

WITH This
     loActiveControl = IIF(TYPE([.oActiveForm.ActiveControl.Name]) = "C", .oActiveForm.ActiveControl, .NULL.)

     IF VARTYPE(loActiveControl) = "O" AND loActiveControl.BaseClass = [Grid]
        lnColumn = loActiveControl.ActiveColumn

        FOR EACH loColumn IN loActiveControl.Columns
            WITH loColumn
                 IF .ColumnOrder <> lnColumn
                    LOOP
                 ENDIF

                 RETURN IIF(NOT (.ReadOnly AND .Bound), EVAL( ([.] + .CurrentControl) ), loActiveControl)
            ENDWITH
        ENDFOR
     ELSE
        RETURN loActiveControl
     ENDIF
ENDWITH
- Jeff
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform