I'm initiating the recursion with this code: Folder root = Folder.Bind(svc, WellKnownFolderName.Inbox) (Assumes there aren't more than 10,000 folders inside a given folder. Noodling around in the code insight, I was able to write what I thought was a method that would traverse the folder structure recursively and result in a combined total for all folders inside the Inbox: private int traverseChildFoldersForSize(Folder f)įoreach (Folder c in f.FindFolders(new FolderView(10000)))įolderSizeSum += traverseChildFoldersForSize(c) įolderSizeSum += (int)f.ManagedFolderInformation.FolderSize ![]() I found one seemingly-applicable question on another site about finding mailbox sizes with EWS 2007, but either I'm not understanding what it's asking me to do, or that method just doesn't work with EWS 2010. I haven't found a web service method to get this data, so I figured I would try to calculate it. ![]() I'm attempting to use EWS 2010 Managed API to get the total size of a user's mailbox.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |