Photo Gallery
Member List
Search
Calendars
FAQ
Ticket List
Log Out
Forums
Register
Login
My Profile
Inbox
Address Book
My Subscription
My Forums
Declaring a vaiable from the results of an array
Logged in as: Guest
arrSession:exec spGetSession 2,3,29878
Active Users: There are
0
members and
0
guests.
Users viewing this topic: none
Printable Version
All Forums
>>
[Scripting]
>>
ASP
>> Declaring a vaiable from the results of an array
Do you like VisualBasicScript.com? Link to us and help spread the word about our forum. Thanks!
Page:
[1]
Login
Message
<< Older Topic
Newer Topic >>
Declaring a vaiable from the results of an array -
1/13/2006 9:40:14 AM
neilbarker100
Posts: 2
Score: 0
Joined: 1/13/2006
Status:
offline
Is it possible to declare a variable from looping through an array.
For example, if I have a 2d array which looks like the following:
2,23
5,2
88,3
Is it possible to loop through the array and populate variables called:
v2 = 23
v5 = 2
v88 = 3
I'm going to then use an if statement to say;
if v5 > 0 and v2 > 0 then .....
Is this possible to do? only I can't make it work.
Post #: 1
RE: Declaring a vaiable from the results of an array -
1/13/2006 9:55:02 AM
ebgreen
Posts: 5069
Score: 31
Joined: 7/12/2005
Status:
offline
It is possible using the Execute command, but using a dictionary or some other data structure is a much better way.
_____________________________
"... when you are good and crazy, oooh, oooh, oooh, the sky is the limit!" - The Tick
Goog places to start:
http://www.visualbasicscript.com/m_24727/tm.htm
http://www.visualbasicscript.com/m_47117/tm.htm
(in reply to
neilbarker100
)
Post #: 2
RE: Declaring a vaiable from the results of an array -
1/13/2006 11:08:46 AM
neilbarker100
Posts: 2
Score: 0
Joined: 1/13/2006
Status:
offline
Would you please be able to show me an example of what you are talking about?
(in reply to
ebgreen
)
Post #: 3
If you found our site useful please link to us
<a href="http://www.visualbasicscript.com">VisualBasicScript.com</a>
.
All Forums
>>
[Scripting]
>>
ASP
>> Declaring a vaiable from the results of an array
Page:
[1]
Jump to:
Select a Forum
All Forums
----------------------
[Welcome]
- - Forum Rules
- - Test Posting Messages
- - New Member Area/Introduction
[Scripting]
- - WSH & Client Side VBScript
- - WSH & Client Side VBScript Tutorial
- - Post a VBScript
- - Windows PowerShell
- - ASP
- - ASP.NET
- - Windows Script Components
[General Forum]
- - Other Programming/Scripting Languages
- - Suggestions & Feedback
- - Off-Topic Lounge
New Messages
No New Messages
Hot Topic w/ New Messages
Hot Topic w/o New Messages
Locked w/ New Messages
Locked w/o New Messages
Post New Thread
Reply to Message
Post New Poll
Submit Vote
Delete My Own Post
Delete My Own Thread
Rate Posts
Forum Software ©
ASPPlayground.NET
Advanced Edition
2.5.5 ANSI