Invoke-GC
SYNOPSIS
Invokes the .NET garbage collector to clean up garbage objects.
SYNTAX
Invoke-GC
DESCRIPTION
Invokes the .NET garbage collector to clean up garbage objects. Invoking a garbage collection can be useful when .NET objects haven't been disposed and is causing a file system handle to not be released.
EXAMPLES
EXAMPLE 1
Invoke-GC
Invokes a garbage collection to free up resources and memory.