Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 11/15/2011 in all areas

  1. Jon

    Double Quote vs Single Quote

    Hey, it proved he at least used the search function!
    4 points
  2. God damn you.
    1 point
  3. russell, If you want to use arrays then you need to learn about loops too! Take a look at this - I think it mirrors what you were trying to do, but with rather more compact code: #include <ComboConstants.au3> #include <GUIConstantsEx.au3> #include <WindowsConstants.au3> Global $reportfile = "C:WindowsTemp" Global $box[8], $field[8] #region ### START Koda GUI section ### Form= $Form1 = GUICreate("Form1", 492, 395, 903, 134) ; Use an array to hold the combo ControlIDs as well - then we can loop through them For $i = 0 To 7 $field[$i] = GUICtrlCreateCombo("", 16, 32 + (24 * $i), 81, 25) GUICtrlSetData(-1, "yes|no") Next GUISetState(@SW_SHOW) #endregion ### END Koda GUI section ### While 1 $nMsg = GUIGetMsg() Switch $nMsg Case $GUI_EVENT_CLOSE Exit EndSwitch Sleep(10000) ExitLoop WEnd ; Now we can loop through the combos and read them For $i = 0 To 7 $box[$i] = GUICtrlRead($field[$i]) If $box[$i] = "yes" Then ; Not quite sure what you wanted to write to the file - you should be able to see what the various options are from this. MsgBox(0, "Writing", $reportfile & "acc" & $i & ".txt" & @CRLF & "account" & $box[$i]) EndIf Next Please ask if you have any questions. M23
    1 point
×
×
  • Create New...