ゴリ押しですけど
#include "user32.as"
//「はい」「いいえ」ボタンに新しく設定する文字列
strYes = "YES!"
strNo = "NO!"
oncmd gosub *Timer, $00000113/*WM_TIMER*/
SetTimer hwnd, 1, 1, 0
dialog "message", 2, "option"
stop
*Timer
GetWindowThreadProcessId hwnd, 0//自ウィンドウのプロセスIDを取得
hp = stat
hw = 0
repeat
FindWindowEx 0, hw, "#32770", 0//ダイアログを検索
hw = stat
if hw = 0 { break }
GetWindowThreadProcessId hw, 0//ダイアログのプロセスIDを取得
if stat = hp {//自ウィンドウが作ったダイアログだったら
FindWindowEx hw, 0, "Button", "はい(&Y)"
SendMessage stat, $0000000C/*WM_SETTEXT*/, strlen(strYes), varptr(strYes)
FindWindowEx hw, 0, "Button", "いいえ(&N)"
SendMessage stat, $0000000C/*WM_SETTEXT*/, strlen(strNo), varptr(strNo)
KillTimer hwnd, 1
break
}
loop
return