Kyme 0 Report post Posted April 8, 2008 i have a noob question: i have 4 GUICtrlCreateRadio expandcollapse popup#include <GUIConstants.au3> $Form1 = GUICreate("GUICtrlCreateRadio", 305, 300, 193, 125) GUISetState(@SW_SHOW) $buton1 = GuiCtrlCreateButton("Start", 100, 190, 100, 50) GuiCtrlCreateGroup("first grup", 45, 40,70,65) $1 = GUICtrlCreateRadio ("5000", 50, 55, 60, 20) $2 = GUICtrlCreateRadio ("10000", 50, 75, 60, 20) GUICtrlCreateGroup ("",-99,-99,1,1) GuiCtrlCreateGroup("secound grup", 120, 40,70,65) $3 = GUICtrlCreateRadio ("15000", 125, 55, 60, 20) $4 = GUICtrlCreateRadio ("20000", 125, 75, 60, 20) GUICtrlCreateGroup ("",-99,-99,1,1) While 1 $msg = GUIGetMsg() Select Case $msg = $GUI_EVENT_CLOSE ExitLoop Case $msg = $buton1 And BitAND(GUICtrlRead($1), $GUI_CHECKED) = $GUI_CHECKED MouseClick("left",834,160,1,1) sleep(5000) MouseClick("left",834,160,1,1) sleep(5000) Case $msg = $buton1 And BitAND(GUICtrlRead($2), $GUI_CHECKED) = $GUI_CHECKED MouseClick("left",834,160,1,1) sleep(10000) MouseClick("left",834,160,1,1) sleep(10000) Case $msg = $buton1 And BitAND(GUICtrlRead($3), $GUI_CHECKED) = $GUI_CHECKED MouseClick("left",834,160,1,1) sleep(15000) MouseClick("left",834,160,1,1) sleep(15000) Case $msg = $buton1 And BitAND(GUICtrlRead($4), $GUI_CHECKED) = $GUI_CHECKED MouseClick("left",834,160,1,1) sleep(20000) MouseClick("left",834,160,1,1) sleep(20000) EndSelect Wend how to make it to work first and secound GuiCtrlCreateGroup in same time??? first grup if it's $1 CHECKED sleep time to be 5000 if $2 CHECKED sleep time to be 10000 secound grup if $3 CHECKED sleep time to be 15000 if $4 CHECKED sleep time to be 20000 and to run like this $1 or $2 and $3 or $4 tnx Share this post Link to post Share on other sites
exodius 1 Report post Posted April 8, 2008 (edited) This'll get you closer to what you want to do... expandcollapse popup#include <GUIConstants.au3> $Form1 = GUICreate("GUICtrlCreateRadio", 305, 300, 193, 125) GUISetState(@SW_SHOW) $buton1 = GuiCtrlCreateButton("Start", 100, 190, 100, 50) GuiCtrlCreateGroup("first grup", 45, 40,70,65) $1 = GUICtrlCreateRadio ("5000", 50, 55, 60, 20) $2 = GUICtrlCreateRadio ("10000", 50, 75, 60, 20) GUICtrlCreateGroup ("",-99,-99,1,1) GuiCtrlCreateGroup("secound grup", 120, 40,70,65) $3 = GUICtrlCreateRadio ("15000", 125, 55, 60, 20) $4 = GUICtrlCreateRadio ("20000", 125, 75, 60, 20) GUICtrlCreateGroup ("",-99,-99,1,1) While 1 $msg = GUIGetMsg() Select Case $msg = $GUI_EVENT_CLOSE ExitLoop Case $msg = $buton1 If GUICtrlRead($1) = $GUI_CHECKED Then MsgBox (0, "#1", "You had #1 checked") MouseClick("left",834,160,1,1) sleep(5000) MouseClick("left",834,160,1,1) sleep(5000) ElseIf GUICtrlRead($2) = $GUI_CHECKED Then MsgBox (0, "#2", "You had #2 checked") MouseClick("left",834,160,1,1) sleep(10000) MouseClick("left",834,160,1,1) sleep(10000) ElseIf GUICtrlRead($3) = $GUI_CHECKED Then MsgBox (0, "#3", "You had #3 checked") MouseClick("left",834,160,1,1) sleep(15000) MouseClick("left",834,160,1,1) sleep(15000) ElseIf GUICtrlRead($4) = $GUI_CHECKED Then MsgBox (0, "#4", "You had #4 checked") MouseClick("left",834,160,1,1) sleep(20000) MouseClick("left",834,160,1,1) sleep(20000) EndIf EndSelect Wend You could then change the If GuiCtrlRead = Statements to be If GuiCtrlRead($var) = $GUI_Checked And GuiCtrlRead($var2) = $GUI_Checked Then... Edited April 8, 2008 by exodius Share this post Link to post Share on other sites
Kyme 0 Report post Posted April 8, 2008 You could then change the If GuiCtrlRead = Statements to be If GuiCtrlRead($var) = $GUI_Checked And GuiCtrlRead($var2) = $GUI_Checked Then...tnxyou help me very muchsee ya Share this post Link to post Share on other sites