Photo Gallery Member List Search Calendars FAQ Ticket List Log Out


Const + class Problem

 
Logged in as: Guest
arrSession:exec spGetSession 2,2,43772
 Active Users: There are 0 members and 0 guests.
 Users viewing this topic: none
 

 

 
  
  Printable Version
All Forums >> [Scripting] >> WSH & Client Side VBScript >> Const + class Problem
  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 >>
 Const + class Problem - 2/26/2007 5:23:18 AM   
  sinshar

 

Posts: 9
Score: 0
Joined: 2/20/2007
Status: offline
I have some code
Let me wing it here
Const NUmberOFItems = 1

Class Myclass

Dim Name(NumberOfItems)
Dim age(NumberOFItems)

' all the property methods here
end class

Name(0) = "Some name
Age(0) = 55

etc.etc.

but i get a Expecting Constant when i try to define them. If define them like so
Dim Name(1)
Dim age(1)

Itworks?
/boggle any ideas?
 
 
Post #: 1
 
 RE: Const + class Problem - 2/26/2007 5:59:50 AM   
  ebgreen


Posts: 5250
Score: 31
Joined: 7/12/2005
Status: offline
I would need to see a more comprehensive example of what you are trying to do. Or better yet actual code.

_____________________________

"... 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 sinshar)
 
 
Post #: 2
 
 
 
  

If you found our site useful please link to us <a href="http://www.visualbasicscript.com">VisualBasicScript.com</a>.
All Forums >> [Scripting] >> WSH & Client Side VBScript >> Const + class Problem Page: [1]
Jump to:





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