//声明SetProcessWorkingSetSize这个Windows API,用于设置操作系统实际划分给进程使用的内存容量
Declare Function SetProcessWorkingSetSize Lib "kernel32" (ByVal hProcess As Long, ByVal dwMinimumWorkingSetSize As Long, ByVal dwMaximumWorkingSetSize As Long) As Long
//声明GetCurrentProcess这个API,来获取当前进程的一个伪句柄
Private Declare Function GetCurrentProcess Lib "kernel32" () As Long
//运行释放系统内存命令
SetProcessWorkingSetSize GetCurrentProcess(),-1,-1