Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Memory consumed when using GRID (VFP6 SP3)
Message
De
10/04/2000 19:12:27
 
 
À
Tous
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Titre:
Memory consumed when using GRID (VFP6 SP3)
Divers
Thread ID:
00357734
Message ID:
00357734
Vues:
54
In a custom GRID class I have code that changes the colour of the grid depending on the deleted status of the record and also highlights the current record. This is achieved using setall dynamicbackcolor command in the grid refresh method:
thisform.nCurRec=recno(this.recordsource)

this.SetAll("dynamicbackcolor",;
   "iif(recno() = thisform.nCurRec, ;
       iif(dele(),RGB(192,192,128),this.rowHighlightColor), ;
       iif(dele(),RGB(197,165,173),RGB(255,255,255)))", ;
    "Column")
When a form with a grid based on this class is active for a long time, it becomes apparent that RAM is being progressively consumed until it exhausts the physical RAM and starts disk swapping. I checked this by adding a textbox that displays the value of sys(1016) as the grid is refreshed, and watched the unused physical memory in the Windows System Monitor.

Removing the grid coloring code resolves the problem. Anyone know why this is happenning.
Sam Robbins BCRTC
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform