Valhalla Legends Forums Archive | Battle.net Bot Development | Need help with script

AuthorMessageTime
TeEhEiMaN
ok im trying to get count users from list to work, I can only get hone channel to work for some reason tho, but heres the code

[\code]
lchan.Text = ChannelName & " (" & lvChannel.ListItems.Count & ")"
[code]

im not sure why it dont work....[/code]
June 11, 2003, 12:28 AM
______
u need to put on user joins,leaves,userin channel
[code]
lchan.Text = ""
lchan.Text = lchan.Text & " (" & lvChannel.ListItems.Count & ")"
[/code]

A very simple way to do it, a better way is to have another textbox to hold the channelname also on your channel join.
exp
[code]
lchan.Text = ""
lchan.Text = NewtxtBox.Text & " (" & lvChannel.ListItems.Count & ")"
[/code]
this would be Channeljoined (any#)
June 11, 2003, 12:54 AM
Stealth
If lchan is a label, you need to use the Caption property to edit its text.
June 11, 2003, 1:06 AM
______
[quote author=Stealth link=board=17;threadid=1608;start=0#msg12054 date=1055293614]
If lchan is a label, you need to use the Caption property to edit its text.
[/quote]
he said he gets the hone channel to work 'home
so i think its not a label.
June 11, 2003, 1:08 AM
Camel
you dont need to set it to "" first
June 11, 2003, 1:32 AM
TeEhEiMaN
Alright I did exacly what u told me, but its still kinda messed up
Problems:
Counts all the users but 1.
When user joins -1
When user Leaves +1

Kinda weird but im not sure what i should do...
June 12, 2003, 12:10 AM
SNiFFeR
[quote author=TeEhEiMaN link=board=17;threadid=1608;start=0#msg12137 date=1055376613]
When user joins -1
When user Leaves +1
[/quote]
maybe switch the codes in each event...Join and Leave...
June 12, 2003, 7:19 PM
St0rm.iD
[quote author=TeEhEiMaN link=board=17;threadid=1608;start=0#msg12051 date=1055291313]
ok im trying to get count users from list to work, I can only get hone channel to work for some reason tho, but heres the code

[\code]
lchan.Text = ChannelName & " (" & lvChannel.ListItems.Count & ")"
[code]

im not sure why it dont work....[/code]
[/quote]

At least he tried. +1
June 12, 2003, 8:47 PM
TeEhEiMaN
what would switchin the same code do?.....
June 12, 2003, 9:21 PM
Eternal
Is it because the index of listboxes/views start with a 0 perhaps? If the Count starts at 0, the first name in the list = 0 not 1.

:P
June 18, 2003, 3:50 PM
Camel
[quote author=Eternal link=board=17;threadid=1608;start=0#msg12590 date=1055951424]
Is it because the index of listboxes/views start with a 0 perhaps? If the Count starts at 0, the first name in the list = 0 not 1.

:P
[/quote]
no. if the count is zero, the list is empty. otherwise it wouldnt be able to speicify zero entries. besides, vb isn't zero-based.
June 18, 2003, 6:45 PM
Eternal
Hmm, I thought they started at -1?
June 18, 2003, 11:16 PM
Skywing
[quote author=Eternal link=board=17;threadid=1608;start=0#msg12620 date=1055978178]
Hmm, I thought they started at -1?
[/quote]
Win32 ListBoxes use -1 to mean 'no item' - however, they index items starting at 0. Of course, "VB ListBoxes" could differ in how they present methods to the user.
June 19, 2003, 12:47 AM
Stealth
When dealing with ListViews, however, 0 means no items; they begin at 1.

God bless VB.
June 19, 2003, 3:30 AM
Yoni
Yes, enjoy diversity within one language.
June 19, 2003, 4:05 AM
Eternal
Well, that's Microsoft for you...
June 19, 2003, 6:53 AM
Camel
[quote author=Yoni link=board=17;threadid=1608;start=0#msg12636 date=1055995535]
Yes, enjoy diversity within one language.
[/quote]
yeah, it's like if one were to take a bunch of white people and a bunch of black people and put them on an island. with cameras. everywhere. said one would be rich! it's iron-tast-ic!



[edit] by the way, i appoligize if i offended anybody; i'm just white trash, you know! :)
June 19, 2003, 11:10 PM
Crypticflare
I'm quite offended you did not use any from the Czech culture, myself and my fellow People of the Czech would like this instance FIXED!!

btw j/k, I understand your point to it though
June 20, 2003, 4:41 AM

Search