OVH Cloud OVH Cloud

Asking for help for PimItemCollection.Restrict() method

1 réponse
Avatar
seebRnet
I am able to only display the appointments of the actual day thanks to
a string filter and using the restrict() method on the Appointment
Collection of my Outlook session.

Indeed, thanks to a string like "[Start] > \"" +
(DateOfTheDay.AddDays(-1)).ToShortDateString() + "\" and [Start] < \""
+ (DateOfTheDay.AddDays(+1)).ToShortDateString() + "\"" and applying it
with the Restrict method as
myAppointmentCollection =
myOutlookSession.Appointments.Items.Restrict(stringFilter);, it
provides the collection containing only appoointments of the
DateOfTheDay.

The problem is when I just change my setting parameters on my Pocket PC
as the separator symbol for displaying dates (for example "/" into
"-"), the restrict method does not work anymore and provides an
PocketOutlookException calling the method Verifyinterface(). Even if, I
put again my last setting parameters when it was functioning, the
application crashes and I just cannot use it since I erase my date on
PPC and reinstall the Windows Mobile OS (what a solution !!!).

Does anybody can help me for this problem ?

Thank you very much

SeebRnet

1 réponse

Avatar
seebRnet
PS : Ne le prenez pas mal si j'ai écrit en anglais mais c'est jsute
que je l'ai posté sur plusieurs groupes à la fois ...

seebRnet a écrit :

I am able to only display the appointments of the actual day thanks to
a string filter and using the restrict() method on the Appointment
Collection of my Outlook session.

Indeed, thanks to a string like "[Start] > "" +
(DateOfTheDay.AddDays(-1)).ToShortDateString() + "" and [Start] < ""
+ (DateOfTheDay.AddDays(+1)).ToShortDateString() + """ and applying it
with the Restrict method as
myAppointmentCollection =
myOutlookSession.Appointments.Items.Restrict(stringFilter);, it
provides the collection containing only appoointments of the
DateOfTheDay.

The problem is when I just change my setting parameters on my Pocket PC
as the separator symbol for displaying dates (for example "/" into
"-"), the restrict method does not work anymore and provides an
PocketOutlookException calling the method Verifyinterface(). Even if, I
put again my last setting parameters when it was functioning, the
application crashes and I just cannot use it since I erase my date on
PPC and reinstall the Windows Mobile OS (what a solution !!!).

Does anybody can help me for this problem ?

Thank you very much

SeebRnet