Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Multiselect Grid
Message
De
11/05/2000 02:10:59
Cetin Basoz
Engineerica Inc.
Izmir, Turquie
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Classes - VCX
Divers
Thread ID:
00368175
Message ID:
00368423
Vues:
3734
>Hi all
>I'am testing the Multiselect Grid class made by Cetin
>and i got a problem
>In the Init event of my form I try to do this
>Thisform.MultiGrid.csql="Pnum,Pnom from Produit Order By Pnum"
>When the form show my Multigrid is affected with the value of a another table open in the data environement.
>
>C'an i change the value of the csql propertie on the fly ?
>I'm sure the class work fine but I'm not sure of me using the class
>
>Thank's
>Ben.


Martineau,
You could change it on the fly. If you drop any grid on form during design and assign no recordsource (cSQL for multiselect) grid populates itself with the alias currently selected. It's a VFP behaviour. If you want to do it in init of form (could be done anywhere) :
with ThisForm.Multiselectgrid1
  .cSQL = "Pnum,Pnom from Produit Order By Pnum"
  .cOrgSource = "produit"
  .init()
endwith
Grid would pull captions from DBC in case it's not a free table. If you want to change captions manually, either use "myHeader1" or alternatively control's index :
ThisForm.Multiselectgrid1.Columns(1).Controls(1).Caption = "myCaption"

Header is always the first control of a column.
PS: If you prepare how would grid look during design (including columncount, captions, caption fonts, columnwidths etc) then do not forget to set lKeepFormat property to .t.
Cetin
Çetin Basöz

The way to Go
Flutter - For mobile, web and desktop.
World's most advanced open source relational database.
.Net for foxheads - Blog (main)
FoxSharp - Blog (mirror)
Welcome to FoxyClasses

LinqPad - C#,VB,F#,SQL,eSQL ... scratchpad
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform