C#|グローバルホットキーを登録するに感銘を受けたので、一部アレンジして、PowerShellから使用できるようにしました。 概要 ホットキーを登録し、登録したキーを押下するとPowerShellコマンドが実行できるようにします。 実装 クラス定義(C#) using System; using System.Collections.Generic; using System.Runtime.InteropServices; using System.Threading; using System.Windows.Forms; //クラス(ホットキー登録・解除用フォーム) public class HotKeyForm : Form { [DllImport("user32.dll")] extern static int RegisterHotKey(IntPtr HWnd, int I