Showing results for arrays hash tables and dictionary objects - Scripting Blog [archived]

Jul 6, 2007
0
0

How Can I Replace Null Values in an Array?

ScriptingGuy1
ScriptingGuy1

Hey, Scripting Guy! How can I loop through a 12x12 array and replace any null values with a hyphen?-- AM Hey, AM. Sorry for the delay in getting back to you; as it turns out, yesterday was Independence Day (more typically referred to as the Fourth of July) in the good old USA, and the Scripting Guys, along with their fellow Microsoft employees,...

Scripting Guy!scripting techniquesVBScript
Jan 27, 2007
0
0

Hey, Scripting Guy! How Can I Get a List of All the Subfolders in a Folder and Then Put That List Into an Array?

ScriptingGuy1
ScriptingGuy1

Hey, Scripting Guy! How can I get a list of all the subfolders in a folder and then put that list into an array?-- PW Hey, PW. We know how anxious you’ve all been, waiting to hear whether the Scripting Guys were successfully moved from Building 43 to Building 42 (yes, directly across from their old building). Well, about the best we can sa...

Scripting Guy!scripting techniquesVBScript
Oct 27, 2006
0
0

How Can I Delete Duplicate Items From an Array?

ScriptingGuy1
ScriptingGuy1

Hey, Scripting Guy! How can I delete duplicate items from an array?-- WR Hey, WR. You know, if Microsoft has a weakness – and we’re not saying that it does, we’re just saying if it does – it’s this: we never make mistakes. (What’s that? What about Windows ME? That’s a weird name; couldn’t possibly be one of our products.) Take arrays, for examp...

Scripting Guy!scripting techniquesVBScript
Sep 22, 2006
0
0

How Can I Verify That All the Items in a List Also Appear in Another List?

ScriptingGuy1
ScriptingGuy1

Hey, Scripting Guy! I have a dumb question for you: If I have two lists how can I verify that all the items in list 2 can be found in list 1?-- SS Hey, SS. Trust us; we’ve heard sillier questions. For example, awhile back the Scripting Son came downstairs on a Saturday morning to find the Scripting Dad eating breakfast. “What’s that?” he said, p...

Scripting Guy!scripting techniquesVBScript
Jul 17, 2006
0
0

How Can I Get the Names of 10 Randomly-Selected Files in a Folder?

ScriptingGuy1
ScriptingGuy1

Hey, Scripting Guy! How can I get the names of 10 randomly-selected files in a folder? I need to do that so I can test and verify our backup and restore policies.-- CS Hey, CS. You know, if you’re interested in things that are random, haphazard, arbitrary, or downright chaotic, well, you came to the right place. For example, any time we Scriptin...

Scripting Guy!scripting techniquesVBScript