Jump to content

Recommended Posts

Posted (edited)

I have 5 checkboxes in total. If $T5Checkbox3 is checked how to continue with the rest of the If statements.

If it's unchecked I have another set to run.

Edit: script is 5 tabs, 600 lines and growing. this is part of Func _Tab_5

Case $T5Button3
    If GUICtrlRead($T5Input1) = "" Then
        MsgBox(0, "Empty.....", "No Drive Selected!")
        Return
    EndIf
    If GUICtrlRead($T5Checkbox3) = $Gui_Checked Then
;>>>>>>>>>>>>>>>If $T5Checkbox3 is checked then continue with following If statements If unchecked I have a different set of If statments to run>>>>>>>>>>>>>>>>>>>>>>>>>
        If GUICtrlRead($T5Checkbox1) = $GUI_CHECKED And GUICtrlRead($T5Checkbox2) = $GUI_CHECKED Then
            RunWait(@ComSpec & ' /k "' & @ScriptDir & '\Dism.exe /Capture-Image /ImageFile:"' & GUICtrlRead($T5Input2) & '" /CaptureDir:' & GUICtrlRead($T5Input1) & ' /Name:"' & GUICtrlRead($T5Input4) & ' /description:' & GUICtrlRead($T5Input5) & ' /Compress:' & GUICtrlRead($T5ComboBox1) & ' /CheckIntegrity /Verify', "")
        ElseIf GUICtrlRead($T5Checkbox1) = $GUI_CHECKED Then
            RunWait(@ComSpec & ' /k "' & @ScriptDir & '\Dism.exe /Capture-Image /ImageFile:"' & GUICtrlRead($T5Input2) & '" /CaptureDir:' & GUICtrlRead($T5Input1) & ' /Name:"' & GUICtrlRead($T5Input4) & ' /description:' & GUICtrlRead($T5Input5) & ' /Compress:' & GUICtrlRead($T5ComboBox1) & ' /CheckIntegrity', "")
        ElseIf GUICtrlRead($T5Checkbox2) = $GUI_CHECKED Then
            RunWait(@ComSpec & ' /k "' & @ScriptDir & '\Dism.exe /Capture-Image /ImageFile:"' & GUICtrlRead($T5Input2) & '" /CaptureDir:' & GUICtrlRead($T5Input1) & ' /Name:"' & GUICtrlRead($T5Input4) & ' /description:' & GUICtrlRead($T5Input5) & ' /Compress:' & GUICtrlRead($T5ComboBox1) & ' /Verify', "")
        Else
            RunWait(@ComSpec & ' /k "' & @ScriptDir & '\Dism.exe /Capture-Image /ImageFile:"' & GUICtrlRead($T5Input2) & '" /CaptureDir:' & GUICtrlRead($T5Input1) & '" /Name:' & GUICtrlRead($T5Input4) & ' /description:' & GUICtrlRead($T5Input5) & ' /Compress:' & GUICtrlRead($T5ComboBox1), "")
        EndIf
Case $T5Button4
Edited by trashy
  • Solution
Posted

Another DUHHHH moment. Just add GUICtrlRead($T5Checkbox3) = $Gui_Checked And,

to the beginning of each If statement.


Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...