Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Grid
Message
De
18/10/2002 03:10:46
 
Information générale
Forum:
Visual FoxPro
Catégorie:
CodeMine
Titre:
Re: Grid
Divers
Thread ID:
00712657
Message ID:
00712729
Vues:
25
Ivan:

>I have a grid which is populated by the records of a cursor created at runtime.

Ah, the dreaded grid question!

>The thing is in a second page of a pageframe, so when the user goes to this page the cursor is appended with records depending on conditions and the grid has this cursor as its RecordSource.

You "APPEND" records to an existing cursor - does this mean that you delete inappropriate records prior to display too? It might be worth reselecting the data using SQL-Select (if you are not using a view). To avoid the loss the of grid's structure, take a look at a couple of Codemine native grid methods; 1) SaveLayout; 2) RestoreLayout. Before the record source is changed, you call, SaveLayout and after the record source has been requeried, call RestoreLayout. This keeps the grid together and provides you with a nice fresh "lean" cursor. I use this technique quite a lot of the time.

>Everything goes fine, the rows have the right information, but I cannot navigate through the rows, not by clicking another one, using the keyboard arrows, nothing. Any ideas why ?

No idea why at this stage. Does the grid work using your approach if it is out of the pageframe? It might be a good idea to try this isolated from the page frame. Get your grid working on its own. Prove it works and then put it back in the pageframe. If you are not using a view, have a look at the methods I have described and simply select the grid's data back into a cursor of the same name.

I don't know why but I am getting a feeling that the problem may lie in the way you are repopulating the record source's data - hence the suggestion to isolate it from the pageframe.

>OK, if you are going to tell me that the approach is completely wrong, don't be so hard ...

Your approach is utterly and completely w@!#g - nah, just kidding!

>I don't want to be depressed for the weekend.

Something tells me that it would take more than this to get you depressed <s>.

Later
-=Gary
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform