M
Mark J. McGinty
Greets,
I'm using GetItemFromID to locate items based on their (surprise surprise)
EntryID values (which I store in a db table and later retrieve, but that's
not important to this question.) I'm passing the folder ID of the folder I
expect them to be in, that I obtain from the EntryID property of the
MAPIFolder object (obtained by calling GetDefaultFolder.)
This all work well, except for one tiny thing: if the user has deleted an
item, and left it in the deleted items folder, the call to GetItemFromID
still finds it there, even though I've explicitly specified a folder in
which to search. This behavior seems anomalous to me, and as luck would
have it, directly undermines my algorithm (rarely, if ever, a good thing.)
So my question, is there a way force GetItemFromID to search in one folder
only? Or alternatively, is there a way to query an item to determine which
folder contains it?
tia,
-Mark
I'm using GetItemFromID to locate items based on their (surprise surprise)
EntryID values (which I store in a db table and later retrieve, but that's
not important to this question.) I'm passing the folder ID of the folder I
expect them to be in, that I obtain from the EntryID property of the
MAPIFolder object (obtained by calling GetDefaultFolder.)
This all work well, except for one tiny thing: if the user has deleted an
item, and left it in the deleted items folder, the call to GetItemFromID
still finds it there, even though I've explicitly specified a folder in
which to search. This behavior seems anomalous to me, and as luck would
have it, directly undermines my algorithm (rarely, if ever, a good thing.)
So my question, is there a way force GetItemFromID to search in one folder
only? Or alternatively, is there a way to query an item to determine which
folder contains it?
tia,
-Mark