#include <ButtonConstants.au3>
#include <EditConstants.au3>
#include <GUIConstantsEx.au3>
#include <WindowsConstants.au3>
#Region ### START Koda GUI section ### Form=
$Form1 = GUICreate("Form1", 498, 337, 429, 263)
$Input1 = GUICtrlCreateInput("", 128, 96, 121, 21)
$Input2 = GUICtrlCreateInput("", 268, 96, 121, 21)
$Input3 = GUICtrlCreateInput("", 128, 178, 121, 21)
$Checkbox1 = GUICtrlCreateCheckbox("Checkbox1", 128, 128, 97, 17)
GUICtrlSetState(-1, $GUI_CHECKED)
$Checkbox2 = GUICtrlCreateCheckbox("Checkbox2", 264, 128, 97, 17)
$leb=GUICtrlCreateLabel("金额",129,70,121,21)
$leb=GUICtrlCreateLabel("应缴税费",269,70,121,21)
$leb=GUICtrlCreateLabel("税后",129,150,90,21)
GUISetState(@SW_SHOW)
#EndRegion ### END Koda GUI section ###
AdlibRegister("shuilv",500)
Dim $a,$b,$c,$d,$e
While 1
$nMsg = GUIGetMsg()
Switch $nMsg
Case $GUI_EVENT_CLOSE
Exit
Case $Checkbox2
If GUICtrlRead($Checkbox2)=$GUI_CHECKED And GUICtrlRead($Input1)<>'' Then
$b=10
Else
$b=0
EndIf
EndSwitch
If BitAND(GUICtrlRead($Checkbox1),$GUI_CHECKED) And GUICtrlRead($Input1)<>'' Then
$a=150
Else
$a=0
EndIf
GUICtrlSetData($Input2,GUICtrlRead($Input1)*$c-$d)
GUICtrlSetData($Input3,GUICtrlRead($Input1)+$a-$b)
Sleep(50)
WEnd
Func shuilv()
If GUICtrlRead($Input1)<2000 Then
$c=0
$d=0
ElseIf GUICtrlRead($Input1)>2000 And GUICtrlRead($Input1)<2500 Then
$e=GUICtrlRead($Input1)-2000
$c=$e*0.05
$b=0
EndIf
EndFunc ;==>