Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
UI - How to track changes?
Message
 
 
À
17/05/2006 16:51:59
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire d'écran & Écrans
Versions des environnements
Visual FoxPro:
VFP 9 SP1
OS:
Windows 2000 SP4
Network:
Windows 2000 Pro
Database:
Visual FoxPro
Divers
Thread ID:
01123001
Message ID:
01123048
Vues:
19
This message has been marked as the solution to the initial question of the thread.
If you change only one filter criteria and leave the rest unchanged, does it mean re-querying again the whole set? In other words, should all filter criteria match the previous?

If the answer is YES, then the simplest solution would be to generate where expression as a string and compare it.

>I've got a form that lets users create reports. The form is in two sections:
>
>1. First section lets users filter the data by a number of criteria
>2. Second section lets them specify GROUP BY and ORDER BY criteria
>
>The data being reported are text files that grow at 60MB/month, currently they total about 175MB. Importing and filtering these data takes several minutes so is therefore "expensive".
>
>It's quite common that users will specify a set of filter criteria, then generate different reports on the same data set using different GROUP BY and/or ORDER BY settings.
>
>What I want to do is avoid unnecessary re-filtering of the data if the user runs a report but has not changed the filter criteria. This means tracking the values of the filter criteria; if they haven't changed since the last report run there's no need to re-import/re-filter.
>
>Can anyone think of an elegant way to do this? What I've thought of so far:
>
>1. Individually tracking control values using form properties. This becomes a maintenance pig if more criteria are added later
>
>2. Putting the filter criteria in a Container, then looping through the container's .Controls collection. This is more generic and has promise, but what's the best way to store the "old" values?
>
>3. Somehow map filter criteria to 2 objects, one with old values, the other with new values. Then, compare the objects.
>
>At the moment the filter criteria controls are unbound so buffering/OLDVAL() etc. aren't available. However, they could be bound to a dummy table if that would be an elegant solution.
If it's not broken, fix it until it is.


My Blog
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform