Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Handling MCN_GETDAYSTATE from month calendar
Message
 
 
À
06/06/2008 19:24:19
Information générale
Forum:
Visual FoxPro
Catégorie:
Fonctions Windows API
Versions des environnements
Visual FoxPro:
VFP 9 SP2
OS:
Windows XP SP2
Divers
Thread ID:
01321939
Message ID:
01322238
Vues:
23
This message has been marked as a message which has helped to the initial question of the thread.
>>
>>I would store AnuallyBoldedDates and MonthlyBoldedDates as an array/collection and also MONTHDAYSTATE values using _Access/_Assign. This way you'll have only build MONTHDAYSTATE when values change which happen less often compare to the number of calls to bold dates.
>>I'm not sure if you can optimize storage of BoldedDates.
>>
>>
>Sergey:
>
>Thank you for your suggestions. I managed it with arrays for AnuallyBoldedDates, MonthlyBoldedDates, and BoldedDates.
>
>The MONTHDAYSTATE 'array' has to be rebuilt from scratch every time you get the getdaystate message, since the change in months displayed could be by one month, or ten years.
>
>So the only solution I came up with is to build the MONTHDAYSTATE 'array' one day at a time: iterate through each element of the AnuallyBoldedDates array to find a match for day/month, then iterate through each element of MonthlyBoldedDates to find a match for day, and then do an ASCAN for the date in BoldedDates.
>

Hi Carlos,

I guess, I didn't explain well what I meant. Yes, the MONTHDAYSTATE 'array' has to be rebuild every time but it doesn't mean that you have to reprocess AnuallyBoldedDates and MonthlyBoldedDates every time date by date. You can keep an array of 12 integers for AnuallyBoldedDates and one integer for MonthlyBoldedDates and populate them only once when related array changes. When it's time to rebuild the MONTHDAYSTATE 'array' you'll combine appropriate integers for AnuallyBoldedDates, MonthlyBoldedDates and than set BoldedDates on top of it.
--sb--
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform