 | | | | |  | | | | | Guest | Need help with a Combobox -
06-04-2007, 10:30 AM
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! | | | | | | | | Guest | Re: Need help with a Combobox -
06-04-2007, 10:30 AM
"What the Hell?" <EMAIL REMOVED>'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 ****y all day. | | | | | | | | Guest | Re: Need help with a Combobox -
06-04-2007, 10:30 AM
Sorry I should have been more specific, When the User picks from a list of
provinces, the label changes to a different tax rate. Like when they pick
"AB" then the label says "6%"
"Jan Hyde" <EMAIL REMOVED> wrote in message
news:EMAIL REMOVED...
> "What the Hell?" <EMAIL REMOVED>'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 ****y all day.
> | | | | | | | | Guest | Re: Need help with a Combobox -
06-04-2007, 10:30 AM
sorry, the code that doesnt work is
Private Sub cboProvince_Click()
If cboProvince.List = "AB" then LblTax.Caption = "6%"
End Sub
"Jan Hyde" <EMAIL REMOVED> wrote in message
news:EMAIL REMOVED...
> "What the Hell?" <EMAIL REMOVED>'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 ****y all day.
> | | | | | | | | Guest | Re: Need help with a Combobox -
06-04-2007, 10:30 AM
"What the Hell?" <EMAIL REMOVED>'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" <EMAIL REMOVED> wrote in message
>news:EMAIL REMOVED.. .
>> "What the Hell?" <EMAIL REMOVED>'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 ****y all day.
>>
>
Jan Hyde (VB MVP)
--
“He’s making a list of chicken and rice,” (Richard Lederer) | | | | | | | | Guest | Re: Need help with a Combobox -
06-04-2007, 10:30 AM
huh, thats the same code that i used, doesn't work
"Jan Hyde" <EMAIL REMOVED> wrote in message
news  EMAIL REMOVED...
> "What the Hell?" <EMAIL REMOVED>'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" <EMAIL REMOVED> wrote in message
>>news:EMAIL REMOVED. ..
>>> "What the Hell?" <EMAIL REMOVED>'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 ****y all day.
>>>
>>
>
>
> Jan Hyde (VB MVP)
>
> --
> "He's making a list of chicken and rice," (Richard Lederer)
> | | | | | | | | Guest | Re: Need help with a Combobox -
06-04-2007, 10:30 AM
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?" <EMAIL REMOVED> wrote in message
news:uN1Mg.37$E67.17@clgrps13...
> huh, thats the same code that i used, doesn't work
>
> "Jan Hyde" <EMAIL REMOVED> wrote in message
> news EMAIL REMOVED...
>> "What the Hell?" <EMAIL REMOVED>'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" <EMAIL REMOVED> wrote in message
>>>news:EMAIL REMOVED ...
>>>> "What the Hell?" <EMAIL REMOVED>'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 ****y all day.
>>>>
>>>
>>
>>
>> Jan Hyde (VB MVP)
>>
>> --
>> "He's making a list of chicken and rice," (Richard Lederer)
>>
>
> | | | | | | | | Guest | Re: Need help with a Combobox -
06-04-2007, 10:31 AM
THANX! That helped SOOO much!
"Raoul Watson" <EMAIL REMOVED> wrote in message
news:K22Mg.9251$ay1.3085@trndny08...
> 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?" <EMAIL REMOVED> wrote in message
> news:uN1Mg.37$E67.17@clgrps13...
>> huh, thats the same code that i used, doesn't work
>>
>> "Jan Hyde" <EMAIL REMOVED> wrote in message
>> news EMAIL REMOVED...
>>> "What the Hell?" <EMAIL REMOVED>'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" <EMAIL REMOVED> wrote in message
>>>>news:EMAIL REMOVED m...
>>>>> "What the Hell?" <EMAIL REMOVED>'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 ****y all day.
>>>>>
>>>>
>>>
>>>
>>> Jan Hyde (VB MVP)
>>>
>>> --
>>> "He's making a list of chicken and rice," (Richard Lederer)
>>>
>>
>>
>
> | | | | | | | | Guest | Re: Need help with a Combobox -
06-04-2007, 10:31 AM
"What the Hell?" <EMAIL REMOVED>'s wild thoughts
were released on Thu, 07 Sep 2006 23:18:50 GMT bearing the
following fruit:
>huh, thats the same code that i used, doesn't work
Then why isn't that the code you posted?
It's important you post your actual code.
J
>"Jan Hyde" <EMAIL REMOVED> wrote in message
>news EMAIL REMOVED.. .
>> "What the Hell?" <EMAIL REMOVED>'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" <EMAIL REMOVED> wrote in message
>>>news:EMAIL REMOVED ...
>>>> "What the Hell?" <EMAIL REMOVED>'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 ****y all day.
>>>>
>>>
>>
>>
>> Jan Hyde (VB MVP)
>>
>> --
>> "He's making a list of chicken and rice," (Richard Lederer)
>>
>
Jan Hyde (VB MVP)
--
The poet had written better poems, but he'd also written verse. | | | | | | | | Guest | Re: Need help with a Combobox -
06-04-2007, 10:31 AM
look who cares, the problem is solved now, if you read the last 2 posts, so
why even bother posting that reply
"Jan Hyde" <EMAIL REMOVED> wrote in message
news:EMAIL REMOVED...
> "What the Hell?" <EMAIL REMOVED>'s wild thoughts
> were released on Thu, 07 Sep 2006 23:18:50 GMT bearing the
> following fruit:
>
>>huh, thats the same code that i used, doesn't work
>
> Then why isn't that the code you posted?
>
> It's important you post your actual code.
>
> J
>
>>"Jan Hyde" <EMAIL REMOVED> wrote in message
>>news EMAIL REMOVED. ..
>>> "What the Hell?" <EMAIL REMOVED>'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" <EMAIL REMOVED> wrote in message
>>>>news:EMAIL REMOVED m...
>>>>> "What the Hell?" <EMAIL REMOVED>'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 ****y all day.
>>>>>
>>>>
>>>
>>>
>>> Jan Hyde (VB MVP)
>>>
>>> --
>>> "He's making a list of chicken and rice," (Richard Lederer)
>>>
>>
>
>
> Jan Hyde (VB MVP)
>
> --
> The poet had written better poems, but he'd also written verse.
> | | | | | Thread Tools | | | | Display Modes | Linear Mode |
Posting Rules
| You may not post new threads You may not post replies You may not post attachments You may not edit your posts HTML code is Off | | | |  |