Professional Documents
Culture Documents
Release Memory On
Release Memory On
dll" (ByVal
hProcess As IntPtr, ByVal dwMinimumWorkingSetSize As Int32, ByVal
dwMaximumWorkingSetSize As Int32) As Int32
Friend Sub ReleaseMemory()
Try
GC.Collect()
GC.WaitForPendingFinalizers()
If Environment.OSVersion.Platform = PlatformID.Win32NT Then
SetProcessWorkingSetSize(System.Diagnostics.Process.GetCurrentProcess().Handle, -1,
-1)
End If
Catch ex As Exception
ex.ToString()
End Try
End Sub