Skip to content

Instantly share code, notes, and snippets.

@Trentent
Trentent / SaveVMBitmap.ps1
Created November 27, 2020 21:16 — forked from jdhitsolutions/SaveVMBitmap.ps1
Sample PowerShell script that shows you how to create a .BMP file of the display of a Hyper-V virtual machine.
function Get-VMScreenBMP {
[cmdletbinding()]
Param(
[string]$VMName,
[string]$Computername = $env:computername,
[string]$Path,
[switch]$Passthru
)
$VMMS = Get-WmiObject -Namespace root\virtualization\v2 -Class Msvm_VirtualSystemManagementService -ComputerName $Computername
@Trentent
Trentent / SaveVMBitmap.ps1
Created November 27, 2020 21:16 — forked from jdhitsolutions/SaveVMBitmap.ps1
Sample PowerShell script that shows you how to create a .BMP file of the display of a Hyper-V virtual machine.
function Get-VMScreenBMP {
[cmdletbinding()]
Param(
[string]$VMName,
[string]$Computername = $env:computername,
[string]$Path,
[switch]$Passthru
)
$VMMS = Get-WmiObject -Namespace root\virtualization\v2 -Class Msvm_VirtualSystemManagementService -ComputerName $Computername
@Trentent
Trentent / PS-BGInfo.ps1
Created October 19, 2020 05:05 — forked from dieseltravis/PS-BGInfo.ps1
update wallpaper background image with powershell (like Sysinternals BGInfo)
# PS-BGInfo
# Powershell script that updates the background image with a random image from a folder and writes out system info text to it.
# run as a lower priority task
[System.Threading.Thread]::CurrentThread.Priority = 'BelowNormal'
# Configuration:
# Font Family name
$font="Input"