Rich, I think there are some easier ways to do this, including a script from MS that reads the data from an Excel file. You could create the Excel file from the csv you already have and go from there. See Clarence Washington's Win32Scripting site at http://cwashington.netreach.net for a number of good examples.
Also, Microsoft's own Script Center is a good place to find pre-built scripts: http://www.microsoft.com/technet/treeview/default.asp?url=/technet/scriptcenter/Default.asp <mc> -----Original Message----- From: Rich Milburn [mailto:[EMAIL PROTECTED] Sent: Friday, November 21, 2003 9:23 AM To: [EMAIL PROTECTED] Subject: [ActiveDir] [slightly OT] scripting add users I think this is a basic question but I am really new to scripting... I'm adding users from a csv file and using an array to read the csv split into lines, then spitting each line into another array (split for commas) from the first array. Do I need to do something to the array#2 before I repopulate it with the next line? If this is confusing, this might help Array1 = Split(objFile, vbCrLf) For n = 1 to Ubound(Array1) '*** do something to Array2 here?? Array2 = Split(Array1(n), ",") 'Call populate users sub Next The reason I ask is I keep getting weird errors that don't seem to correlate to the data being read in (I was getting these when I was reading in one line at a time into Array2) errors like Subscript out of range, etc - and googling only showed things from ASP pages that didn't apply. Thanks for any help Rich -------APPLEBEE'S INTERNATIONAL, INC. CONFIDENTIALITY NOTICE------- PRIVILEGED / CONFIDENTIAL INFORMATION may be contained in this message or any attachments. This information is strictly confidential and may be subject to attorney-client privilege. This message is intended only for the use of the named addressee. If you are not the intended recipient of this message, unauthorized forwarding, printing, copying, distribution, or using such information is strictly prohibited and may be unlawful. If you have received this in error, you should kindly notify the sender by reply e-mail and immediately destroy this message. Unauthorized interception of this e-mail is a violation of federal criminal law. Applebee's International, Inc. reserves the right to monitor and review the content of all messages sent to and from this e-mail address. Messages sent to or from this e-mail address may be stored on the Applebee's International, Inc. e-mail system. List info : http://www.activedir.org/mail_list.htm List FAQ : http://www.activedir.org/list_faq.htm List archive: http://www.mail-archive.com/activedir%40mail.activedir.org/ List info : http://www.activedir.org/mail_list.htm List FAQ : http://www.activedir.org/list_faq.htm List archive: http://www.mail-archive.com/activedir%40mail.activedir.org/
