InvalidCastException in outlook 2003

  • Thread starter Peter van der Veen
  • Start date
P

Peter van der Veen

Hi

In my VB.net application i got on different times (and not allways) an
System.InvalidCastException.

The line of code is:

objAppointmentItem = objItems.GetFirst

Does anyone know what to do???


Peter
 
K

Ken Slovak - [MVP - Outlook]

Are you testing first for any items in the collection? Are you sure that all
the items you are getting are really AppointmentItem?
 
Top