C#でMessageBoxを自動で閉じる方法

メッセージボックスが、例えば5秒で自動的に閉じる、というのを探したところ、結構長いものばかりでした。(私が作ったわけでもないのでアレですが・・・)
そして、google USAで検索したところ大変シンプルな、素敵なのがありました。

http://stackoverflow.com/questions/14522540/close-a-messagebox-after-several-seconds

ただ、テキストの内容が長すぎると(2000文字とか)自動で閉じないケースがあったので、長さを200文字に切り詰めるように、少しだけ追加したのが以下です。

記述の順番は、内容、タイトル、ミリ秒(1000で1秒)です。
AutoClosingMessageBox.Show("内容", "タイトル", 1000);

以下のソースをどこかに置いてください。
public class AutoClosingMessageBox {
int text_max_length = 200; //最大の文字列長の指定
System.Threading.Timer _timeoutTimer;
string _caption;
AutoClosingMessageBox(string text, string caption, int timeout)
{
if( text.length > text_max_length ) //内容の長さを制限する追加部分
{
text = text.Substring( 0, text_max_length );
}
//text = ( text.length > text_max_length ) ? text.Substring( 0, text_max_length ) : text; //三項目演算での記述方法 ? の左側が true の時 : の左側が代入されます。 falseの時は右側
_caption = caption;
_timeoutTimer = new System.Threading.Timer(OnTimerElapsed, null, timeout, System.Threading.Timeout.Infinite);
MessageBox.Show(text, caption);
}
public static void Show(string text, string caption, int timeout) {
new AutoClosingMessageBox(text, caption, timeout);
}
void OnTimerElapsed(object state) {
IntPtr mbWnd = FindWindow(null, _caption);
if(mbWnd != IntPtr.Zero)
{
SendMessage(mbWnd, WM_CLOSE, IntPtr.Zero, IntPtr.Zero);
}
_timeoutTimer.Dispose();
}
const int WM_CLOSE = 0x0010;
[System.Runtime.InteropServices.DllImport("user32.dll", SetLastError = true)]
static extern IntPtr FindWindow(string lpClassName, string lpWindowName);
[System.Runtime.InteropServices.DllImport("user32.dll", CharSet = System.Runtime.InteropServices.CharSet.Auto)]
static extern IntPtr SendMessage(IntPtr hWnd, UInt32 Msg, IntPtr wParam, IntPtr lParam);
}