Skip to content

Instantly share code, notes, and snippets.

@AfterLemon
Forked from anonymous/gist:5910767
Last active December 19, 2015 06:19
Show Gist options
  • Save AfterLemon/5910888 to your computer and use it in GitHub Desktop.
Save AfterLemon/5910888 to your computer and use it in GitHub Desktop.
#NoEnv ; Recommended for performance and compatibility with future AutoHotkey releases.
; #Warn ; Enable warnings to assist with detecting common errors.
SendMode Input ; Recommended for new scripts due to its superior speed and reliability.
SetWorkingDir %A_ScriptDir% ; Ensures a consistent starting directory.
Gui, Add, Text,, Only play/reads/passed in A:
Gui, Add, Edit, gGetTotal vONlyA
Gui, Add, Text,, Only play/reads/passed in B:
Gui, Add, Edit, gGetTotal vOnlyB
Gui, Add, Text,, Play/read/passed in Both:
Gui, Add, Edit, gGetTotal vBC
Gui, Add, Text,, Play/read/passed in None:
Gui, Add, Edit, gGetTotal vnone
Gui, Add, Text, vTotalText, Total: %Total%
Gui,Add,Button,x560 y20 w80 h30,Okay
Gui, Show, center
Return ; end autoexecute
ButtonOkay:
Gui, Submit
Total := none + ONlyA + ONlyB + BC
GuiControl, Text, TotalText, Total: %Total%
return
GetTotal:
Gui, Submit, NoHide
Total := none + ONlyA + ONlyB + BC
GuiControl, Text, TotalText, Total: %Total%
return
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment