• We’re currently investigating an issue related to the forum theme and styling that is impacting page layout and visual formatting. The problem has been identified, and we are actively working on a resolution. There is no impact to user data or functionality, this is strictly a front-end display issue. We’ll post an update once the fix has been deployed. Thanks for your patience while we get this sorted.

ASP/VBScript: Deleting rows from a 2 column array

Pandamonium

Golden Member
I'm trying to come up with a method of deleting a single row of the array, and I can't find or think of any command that will do this automatically.

It seems that the only other option is to copy the array, row by row, to a new array. There would be an if statement regulating the copying - it would flag the row containing the element I want removed and just not copy it. But I'm certain that there's a cleaner method of achieving this end... any ideas?
 
VBscript doesn't have any methods for deleting a row in a multi-dimensional array. You could set all of the items in the row to be 0, which would be easily done in a For Loop, but thats probably not what you need.

Without knowing more about your project all i can advise is maybe you should re-evaluate your algorithm and your need for an array. Perhaps the Scripting.Dictionary object is what you need. http://www.4guysfromrolla.com/webtech/102898-1.shtml
 
Back
Top