How can I get the total physical memory in C#?

前端 未结 5 886
执笔经年
执笔经年 2020-12-15 23:56

I am using the GlobalMemoryStatusEx function to retrieve information about memory, but this function doesn\'t work correctly. It returns 0 for all properties. I

5条回答
  •  渐次进展
    2020-12-16 00:38

    How about:

    My.Computer.Info.TotalPhysicalMemory
    My.Computer.Info.AvailablePhysicalMemory
    

提交回复
热议问题