Go Back   Gaming Gutter > Non-Gaming > Programming


Programming - All general programming discussion in here.

» Site Navigation
» Home
» FAQ
» Log in
User Name:

Password:

Not a member yet?
Register Now!
» Advertisement
» Recent Threads
Go to first new post S> LEOPETS ACCOUNT. xD
Today 02:10 AM
by *God
Last post by plooshiepoo
Today 07:13 AM
4 Replies, 14 Views
Go to first new post What button do you think...
Today 04:45 AM
by Googlrr
Last post by Googlrr
Today 07:12 AM
4 Replies, 15 Views
Go to first new post Post Your Picture
10-09-2006 11:34 PM
by Ryan
Last post by Premia
Today 07:09 AM
8,019 Replies, 111,779 Views
Go to first new post Jtdusk
10-09-2008 01:32 PM
by Cyrus
Last post by Cyrus
Today 07:08 AM
28 Replies, 319 Views
Go to first new post Contest Discussion Thread
04-09-2008 06:40 PM
Last post by sidespin
Today 07:05 AM
175 Replies, 785 Views
Reply
 
LinkBack Thread Tools Display Modes

 Need a Visual Basic Command
Old 12-09-2007, 02:10 PM   #1 (permalink)
Resident Psychopath.

Male Fewmitz is offline


 
Fewmitz's Avatar
 
Join Date: Nov 2006
Location: fewmitz@live.com
Posts: 4,921
iTrader: 1 / 100%
Fewmitz Is a Party CaptainFewmitz Is a Party CaptainFewmitz Is a Party Captain
Rep Power: 15
Need a Visual Basic Command

Okay in Javascript there was a command you could use where you could take a string and an integer and use them in a for loop (or whatever else you want) and use it to sort like an object. Like:

Code:
For i = 0 to 10
  If [command I don't remember]("txt" & i).value = 1 then
     msgBox("text box number " & i "  is equal to 1)
  End If
Next
So you could sort through a series of objects and compare them. But I don't remember what the command was called in Javascript and I need it in VB. So does anyone know of a command that would allow me to do something similar?

If you need further elaboration, let me know, I feel my explanation was lacking.
__________________
When life gives you lemons, get a new God.
  Reply With Quote

 
Old 12-09-2007, 02:28 PM   #2 (permalink)

Male |G3| is online now

 
|G3|'s Avatar
 
Join Date: Feb 2007
Posts: 3,413
iTrader: 7 / 100%
|G3| Total Celebrity|G3| Total Celebrity|G3| Total Celebrity|G3| Total Celebrity|G3| Total Celebrity|G3| Total Celebrity
Rep Power: 19
Ummm something like this?
Code:
For i = 1 To 1000000
Label1.Caption = i
Next
What are you trying to do?
__________________
G3nation
Surf-G3 | ProxyG3 | Glype
GAIA FLP GENERATOR: http://gen.gaiaflps.com/index.php


Thanks Hatz ;3

  Reply With Quote

 
Old 12-09-2007, 03:30 PM   #3 (permalink)
Resident Psychopath.

Male Fewmitz is offline


 
Fewmitz's Avatar
 
Join Date: Nov 2006
Location: fewmitz@live.com
Posts: 4,921
iTrader: 1 / 100%
Fewmitz Is a Party CaptainFewmitz Is a Party CaptainFewmitz Is a Party Captain
Rep Power: 15
The exact opposite actually.

If I have a list of items. lbl1, lbl2, lbl3, etc etc

How would I use a For loop to check to see if they're equal to a number, string, char, etc.

I'm aware I could just use an assload of If Statements, but I can't because of the way I want to use it.
__________________
When life gives you lemons, get a new God.
  Reply With Quote

 
Old 12-10-2007, 03:32 AM   #4 (permalink)
Underground

Male CheeSie is offline
 
CheeSie's Avatar
 
Join Date: Sep 2006
Location: Denmark
Age: 18
Posts: 237
iTrader: 0 / 0%
CheeSie Is gaining popularity
Rep Power: 7
Just put them in a list box and call it like this.

Quote:
Dim x as integer

For x = 0 to lstString.ListCount - 1
If lstString.List(x) = "Blah" then
'code
ElseIF lstString.List(x) = "BlahBlah" Then
'code
Else
'code
End If

Next x
That should work
  Reply With Quote

 
Old 12-10-2007, 07:05 AM   #5 (permalink)

Male |G3| is online now

 
|G3|'s Avatar
 
Join Date: Feb 2007
Posts: 3,413
iTrader: 7 / 100%
|G3| Total Celebrity|G3| Total Celebrity|G3| Total Celebrity|G3| Total Celebrity|G3| Total Celebrity|G3| Total Celebrity
Rep Power: 19
Ohh, I know what you mean. But I don't know how you could do that.
Best bet is do what Cheesie said.

Or do IF's.
__________________
G3nation
Surf-G3 | ProxyG3 | Glype
GAIA FLP GENERATOR: http://gen.gaiaflps.com/index.php


Thanks Hatz ;3

  Reply With Quote

 
Old 12-10-2007, 12:10 PM   #6 (permalink)
Resident Psychopath.

Male Fewmitz is offline


 
Fewmitz's Avatar
 
Join Date: Nov 2006
Location: fewmitz@live.com
Posts: 4,921
iTrader: 1 / 100%
Fewmitz Is a Party CaptainFewmitz Is a Party CaptainFewmitz Is a Party Captain
Rep Power: 15
Blech, I really didn't wanna use lists, but I guess I have to.
__________________
When life gives you lemons, get a new God.
  Reply With Quote

 
Old 12-10-2007, 03:38 PM   #7 (permalink)
Underground

Male CheeSie is offline
 
CheeSie's Avatar
 
Join Date: Sep 2006
Location: Denmark
Age: 18
Posts: 237
iTrader: 0 / 0%
CheeSie Is gaining popularity
Rep Power: 7
why.. .lists are good.
  Reply With Quote

 
Old 12-10-2007, 04:11 PM   #8 (permalink)
Resident Psychopath.

Male Fewmitz is offline


 
Fewmitz's Avatar
 
Join Date: Nov 2006
Location: fewmitz@live.com
Posts: 4,921
iTrader: 1 / 100%
Fewmitz Is a Party CaptainFewmitz Is a Party CaptainFewmitz Is a Party Captain
Rep Power: 15
That doesn't make me want to use them D=
__________________
When life gives you lemons, get a new God.
  Reply With Quote

 
Old 12-10-2007, 04:53 PM   #9 (permalink)
Underground

Male CheeSie is offline
 
CheeSie's Avatar
 
Join Date: Sep 2006
Location: Denmark
Age: 18
Posts: 237
iTrader: 0 / 0%
CheeSie Is gaining popularity
Rep Power: 7
why dont you want to use them then?
  Reply With Quote

 
Old 12-10-2007, 06:01 PM   #10 (permalink)
Resident Psychopath.

Male Fewmitz is offline


 
Fewmitz's Avatar
 
Join Date: Nov 2006
Location: fewmitz@live.com
Posts: 4,921
iTrader: 1 / 100%
Fewmitz Is a Party CaptainFewmitz Is a Party CaptainFewmitz Is a Party Captain
Rep Power: 15
No reason in particular, it would just make the program I'm eventually gonna make .2% easier.
__________________
When life gives you lemons, get a new God.
  Reply With Quote
Reply

Bookmarks



Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Powered by vBadvanced CMPS v3.0 RC2

All times are GMT -7. The time now is 07:14 AM.


vBulletin skin developed by: eXtremepixels
The contents of this webpage are copyright © 2006-2008 GamingGutter.com. All Rights Reserved.

Page generated in 0.17967606 seconds (100.00% PHP - 0% MySQL) with 19 queries