Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Can I base a grid on an array?
Message
De
30/04/1999 02:52:57
Cetin Basoz
Engineerica Inc.
Izmir, Turquie
 
 
À
29/04/1999 13:33:57
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Divers
Thread ID:
00213274
Message ID:
00213791
Vues:
30
>Cetin,
>
>I'm assuming that the array columns pertain to the different data elements, much like fields in a table.
>
>If you are storing different elements within different rows in your array, then my prescribed method of mapping a grid to an array will give you some strange results.
>
>Why wouldn't you use an array with 6 columns for your example and just store the different results in a single row?
>
>i.e. instead of
>myarray[1,1] = "TEST1"
>myarray[1,2] = "TEST2"
>myarray[1,3] = "TEST3"
>myarray[2,1] = .f.
>myarray[2,2] = date()
>myarray[2,3] = 12345
>
>you could have:
>myarray[1,1] = "TEST1"
>myarray[1,2] = "TEST2"
>myarray[1,3] = "TEST3"
>myarray[1,4] = .f.
>myarray[1,5] = date()
>myarray[1,6] = 12345
>
>This way, your array-bound grid would work fine.
>
>I know it works 'cause we have several grids in our app that are mapped to object array properties.
>
>Regards,
>
>-JT
Jeff,
It was an example to show coulmn elements might be different. Yes you can refer to array elements in different notations and get the same element.
For a moment I thought you found a way to cope with array freedom. I would really love it.
In foxbase days I needed something similar and at the end wrote a routine that was getting and setting elements per row via @..get. As user hits down in last row, or up in first row, a routine was filling in new elements :) Not smart but tech of those old days when I didn't even like foxbase browse (it was near the same effect) :)
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
Répondre
Fil
Voir

Click here to load this message in the networking platform