The ViewSize
is specified at constructor level. I found the documentation for the constructor, but it doesn't say how big the maximal size is.

- 2,414
- 5
- 35
- 59

- 1,768
- 2
- 20
- 30
3 Answers
There is limit of 2,147,483,647 as it's data type is Int32, I used it and also tested it not return any error if we pass ItemView(2147483647);
It's just define page size of search item,if there are more search item results than the view page size,subsequent calls that use ItemView offsets must be performed to return the rest of the results.
ref - http://msdn.microsoft.com/en-us/library/exchange/dd633693%28v=exchg.80%29.aspx http://msdn.microsoft.com/en-us/library/system.int32.maxvalue.aspx

- 6,345
- 2
- 37
- 56
-
1but when I do `var privateContacts = service.FindItems(WellKnownFolderName.Contacts, new ItemView(9999));` it always gets me to a limit of 1000... – slow Apr 25 '19 at 09:42
-
HI, @sLw I am sorry to say that I am no more pursuing exchange-server development so I can not further comments or evaluate your saying. If you think my answer is outdated (As posted in 2013) please feel free to update it or create new answer. – Jageen Apr 26 '19 at 02:26
-
I fixed it by using the Answer below by Raja. It goes through every next 1000 records ;) – slow Apr 26 '19 at 05:39
You can specify Int32 value in ItemView constructor but only thousand items will be returnd. You have to specify a loop to get the remaining items.
bool more = true;
ItemView view = new ItemView(int.MaxValue, 0, OffsetBasePoint.Beginning);
view.PropertySet = PropertySet.IdOnly;
FindItemsResults<Item> findResults;
List<EmailMessage> emails = new List<EmailMessage>();
while (more)
{
findResults = service.FindItems(WellKnownFolderName.Inbox, view);
foreach (var item in findResults.Items)
{
emails.Add((EmailMessage)item);
}
more = findResults.MoreAvailable;
if (more)
{
view.Offset += 1000;
}
}

- 153
- 2
- 8
The default policy in Exchange limits the page size to 1000 items. Setting the page size to a value that is greater than this number has no practical effect. Applications should also account for the fact that the EWSFindCountLimit throttling parameter value may result in a partial result set being returned for applications that make concurrent requests.
http://msdn.microsoft.com/en-us/library/office/jj945066(v=exchg.150).aspx

- 51
- 1
- 3