Jump to content

i think this has somthing to do with guiwrite


vickerps
 Share

Recommended Posts

Hi Lads having problems with this code

basically i want it so when they choose a option from the combo box it then populates the list box with details from an ini file. The problem is that the list box uses the value (contaned in a varible) of the combo box.

I think i need to use the guiwrite option to write the state of combo box so that $sites picks up the $cust value

Not sure how to do this thou. Can anyone help

$cust = GUISetControl("combo", "cust",20,20,250)    GUISetControlData(-1,$Customers) ; contains in a ini file$Sites = IniRead("router.ini", Guiread ($cust), "list", "Select Site")$site = GUISetControl("list", "site",140,70,150,40)  GUISetControlData(-1,$sites) contained in a ini file


            
                


    Edited  by vickerps
    
    

            
        

        

        
    

    

    




    Link to comment
    
        
    
    
    

    
    Share on other sites
    

    
        
            

    

        
            

    

        
            

    

        
            

    

        
    


    
    More sharing options...

    


    

                    
                    
                    
                

                    

                    
                    





    

    

    
        
            
                


    
        
    

                
                
                    
                        

                    
                
            
        
        
            
                


CyberSlug
            
            
                Posted 
                
            
        
    
    
        


CyberSlug
            
        
        
            
                
                    


    
        
    

                    
                    
                        

                    
                
            
            
                MVPs
                
                    
                
            
            
                
                    
                        
                            
                                
                            
                                 3.4k
                            
                                
                            
                        
                        
                    
                
            
            
                

    
    
        
Overwhelmed with work....
    
    

            
        
    
    
        



    
        
            
                
                    
                    
                    
                    
                    
                
            
            
                
                    
                    
                        
                        
                            Share
                        
                        
                        
                        
                        
                            
                                
                            
                            
                            
                            
                            
                            
                        
                    
                
                
            
        

        
            Posted 
            
            
                
                
            
        
    

    

    

    
        
        
            What kind of message loop are you using?  When you detect that the combo has been clicked, call GuiRead(...) on it.
; Script generated by AutoBuilder 0.5 Prototype

GuiCreate("MyGUI", 392, 323,(@DesktopWidth-392)/2, (@DesktopHeight-323)/2 , 0x04CF0000)

$Combo = GuiCtrlCreateCombo("", 20, 70, 110, 21)
GuiCtrlSetData($combo, "One|Two|Three")
$List = GuiCtrlCreateList("", 170, 70, 100, 110)

GuiSetState()
While 1
    $msg = GuiGetMsg()
    Select
    Case $msg = -3;Should really use $GUI_EVENT_CLOSE
        ExitLoop
    Case $msg = $Combo
        $item = GuiRead($Combo);text of selected item
      GuiCtrlSetData($List, "|" & $item & "|" & $item & "|" & $item & "|" & $item);add new data...
    EndSelect
WEnd
Exit
Use Mozilla | Take a look at My Disorganized AutoIt stuff | Very very old: AutoBuilder 11 Jan 2005 prototype I need to update my sig!
Link to comment
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
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...