通知領域にメッセージを表示する

変数を設定 [$Result; 値:

SMPS_ExecSync( "param([int]$timeout = 3, [string]$tilte = '{tilteタイトル}', [string]$body = '{body}', [string]$toolTipIcon = 'Info');

[Void][System.Reflection.Assembly]::LoadWithPartialName('System.Windows.Forms');

$notifyIcon = New-Object System.Windows.Forms.NotifyIcon;

$powerShellExe = $PSHOME+'/powershell.exe' ;

$icon = [System.Drawing.Icon]::ExtractAssociatedIcon($powerShellExe);

$notifyIcon.Icon = $icon;

$notifyIcon.Visible = $true;

$notifyIcon.ShowBalloonTip($timeout, $tilte, $body, $toolTipIcon);

$notifyIcon.Visible = $false;" )

]

参考:

Windows PowerShell Tip: Displaying a Message in the Notification Area :

http://technet.microsoft.com/en-us/library/ff730952.aspx

Balloon Notifications with Powershell | Learn Powershell | Achieve More :

http://learn-powershell.net/2010/08/22/balloon-notifications-with-powershell/