I have been asked to update a table with data that has been entered by uses
in thier MySites. I would like to use the ProfileManagers.GetChange method
to return the profiles that have recently been changed.
The get changes method always returns 1000 profiles. I have not found a way
to set a flag to identifiey processed profiles.
Another option appears to be to add a query to the GetChanges method.
Within the query there is the option of setting a ChangeTokenStart property
with a date. Setting this date does not appear to effect the results (I
still get 1000 profiles).
I have added the code below. If anyone has any ideas I would much
appreciate the help.
SPSite site = new SPSite("http://XXXXsps:8082/");
ServerContext srvContext = ServerContext.GetContext(site);
UserProfileManager profileManager = new
UserProfileChangeQuery query = new UserProfileChangeQuery();
query.PersonalizationSite = true;
query.ChangeTokenStart = new UserProfileChangeToken(new
DateTime(2007, 7, 19, 1, 0, 0));
UserProfileChangeCollection col = profileManager.GetChanges(query);