I think im pretty close to gettin this but, can you tell me what to change, Fix.
Private Sub channels()
If Username = Form5.txtMaster.Text Then
If Left((LCase(Message)), 12) = (Form5.txtTrigger.Text & "addchannel ") Then
Dim chanuser As String
cmbchannellist.combo.AddItem = "chanuser"
End If
End If
End Sub
You didnt set chanuser
chanuser = Right(Message, (Len(Message) - 12))
put that right above your
cmbchannellist.combo.AddItem = "chanuser"
chanuser=Mid(Message,13)
cmbchannellist.combo.AddItem = chanuser
Quote from: ______ on May 26, 2003, 06:12 PMYou didnt set chanuserchanuser = Right(Message, (Len(Message) - 12))
put that right above yourcmbchannellist.combo.AddItem = "chanuser"
That code will still add "chanuser" instead of what's stored in chanuser.
I dont think that cmbchannellist.combo is right, Its suppost to be like txtchannellist.text for a text Box, but what would it be for a combo box??? please respond fast
Quote from: TeEhEiMaN on May 26, 2003, 06:43 PMwhat would it be for a combo box???
Try searching on google or Microsoft...
http://www.google.com/search?hl=en&lr=&ie=UTF-8&oe=UTF-8&q=%22combo+box%22+%22visual+basic%22+adding+items (http://www.google.com/search?hl=en&lr=&ie=UTF-8&oe=UTF-8&q=%22combo+box%22+%22visual+basic%22+adding+items)
Google: The answer to the world's problems.
EDIT: Added url tags to link correctly.
Quote from: TeEhEiMaN on May 26, 2003, 06:43 PM
I dont think that cmbchannellist.combo is right, Its suppost to be like txtchannellist.text for a text Box, but what would it be for a combo box??? please respond fast
ever think to try cmbchannellist.text?
Nope that dont work...
omg this is weird!!!!!!
Why does this code not work?!
Private Sub channels()
If Username = Form5.txtMaster.Text Then
If Left((LCase(Message)), 12) = (Form5.txtTrigger.Text & "addchannel ") Then
Dim chanuser As String
chanuser = Right(Message, (Len(Message) - 12))
Combo1.AddItem = "chanuser"
End If
End If
End Sub
In what way does it not work? In what way do you wish it to work? Stop being a <expletives removed>, and try to help us help you!
This won't fix whatever the problem is, but I'd use
chanuser = Mid(Message, 13)
instead of
chanuser = Right(Message, (Len(Message) - 12))
... Just because it's easier to figure out at a glance (I think).
Quote from: TeEhEiMaN on May 26, 2003, 07:59 PM
Combo1.AddItem = "chanuser"
dont use quotes around chanuser
Quote from: OcTaViuS on May 27, 2003, 10:39 AM
Quote from: TeEhEiMaN on May 26, 2003, 07:59 PM
Combo1.AddItem = "chanuser"
dont use quotes around chanuser
yes otherwise your just adding "chanuser" as text not a string