Only problem is that it doesn't seem to add the network in the script, or one that I edit in, to my list of preferred networks.

I'm looking for a solution to getting a new network along with the WPA key onto about 500 laptops which are scattered around the British Isles.

Am I doing something wrong !? The script runs, opens the wireless config wizard and then it just sits there as if waiting for me to enter details. The first time I ran it it stayed on the screen for 5 seconds and disappeared.

Hard to say what the problem is - this isn't so much a script as it is a hack...
What it tries to accomplish is an automated walkthrough thru the wireless network setup.
Line 8 was the working delay for that user, you may need to increase it - it's in milliseconds, so that's about a 1 sec pause.

Try manually stepping through the key sequences.
Click Start->Run->netsetup.cpl <Enter>
??How long do you typically need to wait here??
Longer than 1 sec, increase the timer.

Now hit <Alt> + NSN
You should be at the SSID prompt - enter the network name there and press <Alt> MN (to 'manually' setup the key and 'click' next)
Now hit <Alt> W - type the key
<Alt> O to confirm it
and <Alt> NSN then <Tab> and <Space> (to finish).

Does that work? What changes were needed?

The underlying problem is, like I said, this isn't really a solution script. Anyone trying to run this to automate the process should be aware (or at least distracted) that it's running because any user interaction while it's running can take away the focus of the network setup wizard and there's no error trapping involved here - the script would simply fail.

If you're aware of that and finding problems with your personal testing anyway, then the steps above should help identify the problem and hopefully a workaround.

Are you asking a question?
Haven't heard anything from you in four months, so I'm not sure what you wanted from me here.
I told you upfront this was more of a hack than a solution, but without your feedback and interaction, there's no way for any expert to determine how to help you.

Next we export the settings from the needed profile, in this case MCSD:

C:\WLAN.exe gp 8d91c644-2e6b-46e7-b346-82b7b0f787a9 MCSD>export.xml

On the target machine the GUID must be queried by using the ei command:

wlan.exe ei

once we have the target GUID we can apply the export file to it:

c:\wlan.exe sp NewGuidFromTarget C:\export.xml

This is the process to complete it, a user naamed tomssd on the Symantec forum where this tool is available from created a script to deploy this to multiple machines, and we verified it works.
Good luck!!

I don't have a vbscript to offer and I know this is under the vbscript forum. However, vbscript is not the simplest way to do this, which is hard for me to say as I am a vbscript diehard!! lol

Using wlan.exe mentioned by MCSDexpert above, the following CMD/BAT will added multiple SSID's to a laptop/pc providing the XML is named after the SSID. See MCSDexpert's post for how to export a config to XML.

Multi-source agreements are important because they set standards that all manufacturers should follow to ensure that devices are compatible with multiple vendors. The multi-source agreement (MSA) is an agreement that establishes how multiple vendors…

This Micro Tutorial will show you how to maximize your wireless card to its maximum capability.
This will be demonstrated using Intel(R) Centrino(R) Wireless-N 2230 wireless card on Windows 8 operating system.

Viewers will learn how to connect to a wireless network using the network security key. They will also learn how to access the IP address and DNS server for connections that must be done manually.
After setting up a router, find the network security…