Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
How to doubleclick a record in a grid to activate a form
Message
De
29/07/2008 06:31:47
 
 
À
29/07/2008 05:49:39
Sonny Tabano
Trams Printwork, Inc.
Mabalacat, Philippines
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire d'écran & Écrans
Versions des environnements
Visual FoxPro:
VFP 9 SP1
OS:
Windows XP
Network:
Windows XP
Database:
Visual FoxPro
Divers
Thread ID:
01334808
Message ID:
01334811
Vues:
20
How to use double clicking a record in a grid to activate a form?

This code in the grid class's Init:
*** now make sure that the dblclick method of all the contained text boxes
*** delegate to the grid's dblclick()
FOR lnCol = 1 TO This.ColumnCount
  loColumn = This.Columns[ lnCol ]
  FOR EACH loControl IN loColumn.Controls
      IF PEMSTATUS( loControl, [dblClick], 5 )      
        BINDEVENT( loControl, 'dblClick', This, 'dblClick' )  
      ENDIF
  ENDFOR
ENDFOR
Now, in the instance of the grid on the form you can put this code in the grid's dblclick()
DO FORM MyChildForm NAME loChildForm LINKED
And also, can a combobox be used in a grid?

Go to the tools and utilities page of my web site and download the white paper and code samples from my conference presentation called "How to Put a Combo in a Grid". You will have all the information (and examples) that you need.
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform