home bbs files messages ]

Forums before death by AOL, social media and spammers... "We can't have nice things"

   comp.lang.visual.basic      MS Visual Basic discussions, NOT dot-net      10,840 messages   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]

   Message 10,214 of 10,840   
   Raoul Watson to randypuderak@gmail.com   
   Re: Need help with a Combobox   
   07 Sep 06 23:37:14   
   
   From: WatsonR@IntelligenCIA.com   
      
   Sorry for the top post.. how about..   
      
   Private Sub cboProvince_Click()   
        if cboProvince.List(cboProvince.ListIndex) = "AB" then LblTax.Caption =   
   "6%"   
   ' ... etc.   
   End Sub   
      
      
   "What the Hell?"  wrote in message   
   news:uN1Mg.37$E67.17@clgrps13...   
   > huh, thats the same code that i used, doesn't work   
   >   
   > "Jan Hyde"  wrote in message   
   > news:om90g2h0jc7r55gkm99thhvvtvpeql7r40@4ax.com...   
   >> "What the Hell?" 's wild thoughts   
   >> were released on Thu, 07 Sep 2006 13:43:37 GMT bearing the   
   >> following fruit:   
   >>   
   >>>sorry, the code that doesnt work is   
   >>>   
   >>>Private Sub cboProvince_Click()   
   >>>    If cboProvince.List = "AB" then LblTax.Caption = "6%"   
   >>   
   >> If cboProvince.Text = "AB" then LblTax.Caption = "6%"   
   >>   
   >>   
   >>   
   >>   
   >>   
   >>>End Sub   
   >>>"Jan Hyde"  wrote in message   
   >>>news:r1jvf254cpe5ldia7q7bl66pm5hcs7qpro@4ax.com...   
   >>>> "What the Hell?" 's wild thoughts   
   >>>> were released on Thu, 07 Sep 2006 02:36:19 GMT bearing the   
   >>>> following fruit:   
   >>>>   
   >>>>>   I have a question for people out there, I need the Combobox to   
   >>>>> change a   
   >>>>>label caption when the user picks a certain thing from the list. How do   
   >>>>>I   
   >>>>>code this. I've tried an If Then statement, but it doesn't seem to   
   >>>>>work.   
   >>>>>Somebody please help!   
   >>>>>   
   >>>>   
   >>>> Post the code that doesn't work.   
   >>>>   
   >>>> Anyway,   
   >>>>   
   >>>> Private Sub Combo1_Click()   
   >>>>  Label1.Caption = Combo1.Text   
   >>>> End Sub   
   >>>>   
   >>>>   
   >>>>   
   >>>> Jan Hyde (VB MVP)   
   >>>>   
   >>>> --   
   >>>> Man with hole in pocket feel cocky all day.   
   >>>>   
   >>>   
   >>   
   >>   
   >> Jan Hyde (VB MVP)   
   >>   
   >> --   
   >> "He's making a list of chicken and rice," (Richard Lederer)   
   >>   
   >   
   >   
      
   --- SoupGate-Win32 v1.05   
    * Origin: you cannot sedate... all the things you hate (1:229/2)   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]


(c) 1994,  bbs@darkrealms.ca