<# .NOTES =========================================================================== FileName: spmover1.ps1 Author: SebastienQUEROL Created On: 2024/03/07 Last Updated: 2024/03/07 Organization: Version: v0.1 =========================================================================== .DESCRIPTION .DEPENDENCIES #> # ScriptBlock to Execute in STA Runspace $sbGUI = { param($BaseDir) #region Environment Setup try { Add-Type -AssemblyName System.Windows.Forms Add-Type -AssemblyName System.Drawing } catch {Update-ErrorLog -ErrorRecord $_ -Message "Exception encountered during Environment Setup."} #endregion Environment Setup #region Dot Sourcing of files $dotSourceDir = $BaseDir . "$($dotSourceDir)\Functions.ps1" . "$($dotSourceDir)\Events.ps1" #endregion Dot Sourcing of files #region Form Initialization try { ConvertFrom-WinFormsXML -Reference refs -Suppress -Xml @"