Jump to content
Sign in to follow this  
Triton

Need Some Help!

Recommended Posts

Triton

I can't seem to get my buttons to do what I want them to do based on my selections. Here's my code:

Func maingui()
    guicreate("Run Workstation Updates?",300,250,)
  guisetcontrol("group","Choose Update Method",10,5,280,50)
  global $all = guisetcontrol("radio","All Updates",35,25,100,20)
    guisetcontrolex(-1,$GUI_CHECKED)
    guisetcontrolnotify()
     global $selected = guisetcontrol("radio","Select Updates",160,25,100,20)
    guisetcontrolnotify()
    
  guisetcontrol("group","Choose Updates",10,65,280,100)
     global $bios = guisetcontrol("checkbox","BIOS",35,100,100,20)
    guisetcontrolex(-1,128)
     global $wsn = guisetcontrol("checkbox","WS Name",35,125,100,20)
    guisetcontrolex(-1,128)
     global $wsu = guisetcontrol("checkbox","Delete WSU",140,100,100,20)
    guisetcontrolex(-1,128)
     global $wmp = guisetcontrol("checkbox","Delete WMP",140,125,100,20)
    guisetcontrolex(-1,128)
    
     global $btn1 = guisetcontrol("button","Run",40,200,100,25)
    
     global $btn2 = guisetcontrol("button","Quit",155,200,100,25)
    
     While guimsg() >0
    If guiread($all) = $GUI_CHECKED then
     guiwrite($bios,128)
     guiwrite($wsn,128)
     guiwrite($wsu,128)
     guiwrite($wmp,128)
    ElseIf guiread($all) = $GUI_UNCHECKED then
     guiwrite($bios,64)
     guiwrite($wsn,64)
     guiwrite($wsu,64)
     guiwrite($wmp,64)
    Endif
     Wend
  guiwaitclose()
  If $btn2 = "quit" Then
     guidelete()
     exit
  Else
     Return
  Endif
EndFunc

:angry:B):whistle:


Triton

Share this post


Link to post
Share on other sites

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
Sign in to follow this  

×