Add-Type -Assembly System.Windows.Forms
Function ActiveCell_Value
{
  Write-Host '***** ActiveCell Start*****';
    #=== 稼働中の Excel を捕まえる
    $ex = [System.Runtime.InteropServices.Marshal]::GetActiveObject("Excel.Application")
    # エクセル ステータスバー $ex.StatusBar = "現在のセルをメッセージボックスで表示"

    if ($ex -eq $null) { return $null }
    return $ex.ActiveCell.Text;
}