Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Resetting grids
Message
 
 
À
Tous
Information générale
Forum:
Visual FoxPro
Catégorie:
Classes - VCX
Titre:
Resetting grids
Divers
Thread ID:
00156378
Message ID:
00156378
Vues:
64
In my grid class, I put code to set up the grid according to saved settings:
      RESTORE FROM MEMO Settings ADDITIVE
      THIS.RecordSource = THIS.RecordSource
      FOR i = 1 TO THIS.ColumnCount
         THIS.Columns[i].Header1.Caption = laSets[i,1]
         THIS.Columns[i].ControlSource = laSets[i,2]
         THIS.Columns[i].Width = laSets[i,3]
         THIS.Columns[i].ColumnOrder = laSets[i,4]
      ENDFOR
For the most part this works, but there's one problem. Comboboxes in the grid don't initialize. I have the cbo rowsource as an SQL statement and the rstype as SQL. When I don't have this code in the grid, the combobox opens a table and creates a cursor and populates itself. With the code, it doesn't do any of that.

I've narrowed it down to it being setting the controlsource that's causing this. Without that line, the cbos work. Unfortunately, without that line the columns have no control sources.

Any idea what I can do to make this work?

Thanks,

-Michelle
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform