HSPポータル
サイトマップ お問い合わせ


HSPTV!掲示板


未解決 解決 停止 削除要請

2011
1218
vdghtyhtde最大化2未解決


vdghtyhtde

リンク

2011/12/18(Sun) 19:10:58|NO.43830

チェックボックスにチェックが入ると最大化、ないと通常の状態で、テキストに保存されて次回起動させてもテキスト通りになるようにしたいのです。


#include "user32.as" screen 0, ginfo(20)-30, ginfo(21)-30 GetWindowLong hwnd, -16 SetWindowLong hwnd, -16, stat | $10000 | $40000 notesel buf noteload "setting.txt" sdim saidaika2 , 1 noteget sidaika2 , 21 if int(saidaika) = 0 : width 600,600 if int(saidaika) = 1 : sendmsg hwnd,$112, $F030 *test chkbox "test" , saidaika button "", *test2 stop *test2 notesel buf noteload "setting.txt" noteadd str(saidaika) , 21, 1 goto *test3 *test3 notesel buf noteload "setting.txt" sdim saidaika2 , 1 noteget sidaika2 , 21 if int(saidaika) = 1 : sendmsg hwnd, $112, $F030 goto *test4 *test4 stop
どこを修正すればいいのでしょう。教えてください。



この記事に返信する


とおりすがり

リンク

2011/12/18(Sun) 22:50:06|NO.43834

設定を変更したら、setting.txt に変更を保存しなければいけませんね。



fortunehill

リンク

2011/12/18(Sun) 22:51:13|NO.43835

ご参考。


#include "user32.as" screen 0,ginfo_dispx,ginfo_dispy,,,,640,480 GetWindowLong hwnd, -16 SetWindowLong hwnd, -16, stat | $10000 exist "setting.txt" if (strsize != -1) {bload "setting.txt",saidaika} chkbox "test", saidaika oncmd gosub *syscommand, $112 onexit *close ;タイマーで1秒間隔でsaidaikaをチェック Settimer hwnd,100,1000,0 oncmd gosub *timer, $113 /* ;無限ループでsaidaikaをチェック repeat if (saidaika) {ShowWindow hwnd,3}else {ShowWindow hwnd ,1} await loop */ stop *timer if (saidaika) {ShowWindow hwnd,3}else {ShowWindow hwnd ,1} return *syscommand if (wparam == $F120) or (wparam == $F030) {saidaika = saidaika^1 :objprm 0,saidaika} return *close bsave "setting.txt",saidaika end



ONION software Copyright 1997-2023(c) All rights reserved.