*moves to API forum*
You can use the ListFolderAsync and ListFolderContinueAsync methods in the .NET SDK to list the items in a folder. You can then count the number of files in your app's code.