Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Refreshing Object
Message
De
02/08/2005 04:29:56
 
 
À
02/08/2005 04:03:21
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Versions des environnements
Visual FoxPro:
VFP 9
Divers
Thread ID:
01037726
Message ID:
01037736
Vues:
17
This message has been marked as a message which has helped to the initial question of the thread.
My suggestion is to avoid creating a separate refresh method if possible, instead you should put the refresh code where it belongs, namely in the refresh event if each object, sometimes together with Nodefault-code-Dodefault. This way to design also encapsulates all the objects, so it's easy to copy or move them to other forms and pages, without having to change any code.

Earlier I used to create a seperate Update function, but I found that this caused refresh to be called more than once for many objects.

>well, answering to Thore : Yes I use Lockscreen
>
>Hi Craig, those object are shapes and the refresh methods of them just check some properties and sets the proper backcolor and borderColor of the shape.
>
>Actually I put the code in another method and I'm trying to call it programmatically when I need to. But I'm still trying :-)
>
>
>>Without more information, such as the code itself or what the code in the refresh event is doing exactly, it is really difficult to offer anything meaningful in the way of help. 1000 objects on a single form seems like quite a few, depends on what you're doing with them though. 1000 lines is a lot different than 1000 grids for instance.
>>
>>>I run into this problem :
>>>I have a form which contains about 1000 objects of the same class.
>>>To correctly display those objects, I mean backColor ecc. , I put some code in the refresh method of the class. The point is that when I run the form it takes 5 - 10 seconds to get available. I tried to avoid the refresh code and it run much faster.
>>>Where should I put this code ? Or is there a way to control this method ? I was thinking about a thermometer to make the waiting less unpleasant ?
>>>
>>>Thanks
>>>Alessio
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform