@msdn=http://search.microsoft.com/search/results.aspx?qu=$$$ @pinvoke=http://pinvoke.net/$$$.htm Summary: Retrieves the amount of RAM, in kilobytes, that is physically installed on the computer. !!!!C# Signature: [DllImport("kernel32.dll", SetLastError=true)] [return: MarshalAs(UnmanagedType.Bool)] static extern bool GetPhysicallyInstalledSystemMemory(out ulong MemoryInKilobytes); !!!!VB Signature: Declare Function GetPhysicallyInstalledSystemMemory Lib "kernel32.dll" (ByRef TotalMemoryInKilobytes As ULong) As Boolean !!!!User-Defined Types: None. !!!!Alternative Managed API: Do you know one? Please contribute it! !!!!Notes: None. !!!!Tips & Tricks: Please add some! !!!!Sample Code: [DllImport("kernel32.dll")] [return: MarshalAs(UnmanagedType.Bool)] static extern bool GetPhysicallyInstalledSystemMemory(out ulong TotalMemoryInKilobytes); static void Main() { ulong l; GetPhysicallyInstalledSystemMemory(out l); Console.WriteLine((l / 1024) + "MB of RAM installed."); Console.ReadLine(); } Documentation: GetPhysicallyInstalledSystemMemory@msdn on MSDN
Edit kernel32.GetPhysi...
You do not have permission to change this page. If you feel this is in error, please send feedback with the contact link on the main page.