I understand that the answer to this question may depend on registry settings and on the version of Windows, and perhaps on the amount of RAM if there is not enough memory. For
Since those values could change with new Windows versions, you can use the SysInternals tool TestLimit
/ TestLimit64
to get a rough estimate. The x64 version may run for a while, especially for the memory test (it might use the hard disk (swap file) to get more virtual memory).
Get the tools from http://live.sysinternals.com/WindowsInternals/ or http://download.sysinternals.com/files/TestLimit.zip
Command line options:
-p check process limit
-t check thread limit
-h check handle limit
-u check user handle limit