以下のスクリプトで、GetWindowText WH,varptr(titleStr),255の部分で「変数名が指定されていません」というエラーが出ます。
これは、#func GetWindowText ・・・ の部分が有効になっていないということでしょうか?
#uselib "user32.dll" #func GetForegroundWindow "GetForegroundWindow" #func GetWindowText "GetWindowTextA" int, var, int #func SetWindowText "SetWindowTextA" int, sptr ;main===================================================== sdim titleStr,255 GetForegroundWindow WH=stat GetWindowText WH,varptr(titleStr),255 titleStr2=titleStr+" 時報がONになっています" SetWindowText WH,titleStr2 stop