Snitz Forums 2000
Snitz Forums 2000
Home | Profile | Register | Active Topics | Members | Search | FAQ
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 Community Forums
 Code Support: ASP (Non-Forum Related)
 Dim multi dimensional array
 New Topic  Topic Locked
 Printer Friendly
Author Previous Topic Topic Next Topic  

Podge
Support Moderator

Ireland
3776 Posts

Posted - 25 August 2007 :  14:57:07  Show Profile  Send Podge an ICQ Message  Send Podge a Yahoo! Message
This is probably very simple but I cannot seem to get it.

const bound = cInt(Matches.Count)
Dim KeysItems(1, bound)


Matches.Count should return an integer.

I'm trying to create a multi dimensional array the same size as the Matches collection. The Matches collection will always be different so I have to dim the array dynamically. The above code generates the following error.
Microsoft VBScript compilation error '800a0402' 
Expected integer constant 
line 1650 
Dim KeysItems(1, bound)
-----------------^


Any ideas?

Podge.

The Hunger Site - Click to donate free food | My Blog | Snitz 3.4.05 AutoInstall (Beta!)

My Mods: CAPTCHA Mod | GateKeeper Mod
Tutorial: Enable subscriptions on your board

Warning: The post above or below may contain nuts.

Podge
Support Moderator

Ireland
3776 Posts

Posted - 25 August 2007 :  15:05:30  Show Profile  Send Podge an ICQ Message  Send Podge a Yahoo! Message
I love answering my own posts. You have to use reDim.
Dim KeysItems()
const bound = cInt(Matches.Count)
reDim KeysItems(1, bound)

Podge.

The Hunger Site - Click to donate free food | My Blog | Snitz 3.4.05 AutoInstall (Beta!)

My Mods: CAPTCHA Mod | GateKeeper Mod
Tutorial: Enable subscriptions on your board

Warning: The post above or below may contain nuts.
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Topic Locked
 Printer Friendly
Jump To:
Snitz Forums 2000 © 2000-2021 Snitz™ Communications Go To Top Of Page
This page was generated in 0.23 seconds. Powered By: Snitz Forums 2000 Version 3.4.07