Valuater Posted September 23, 2005 Share Posted September 23, 2005 (edited) EDIT Got it... thanks for checking 8) Edited September 23, 2005 by Valuater Link to comment Share on other sites More sharing options...
seandisanti Posted September 23, 2005 Share Posted September 23, 2005 been at this all morning....just need a little helpFor $b = 1 to 1000 If @error Then ExitLoop $bRead = FileReadLine($file2, $b) $bSplit = StringSplit($bRead, ",") $TbRecords [0][0] = $bSplit[0] $TbRecords [$b][1] = $bSplit[1] $TbRecords [$b][2] = $bSplit[2] $TbRecords [$b][3] = $bSplit[3] $TbRecords [$b][4] = $bSplit[4] $TbRecords [$b][5] = $bSplit[5] _ArraySwap($TbRecords[$b][1], $TbRecords[$b][2]) _ArraySort( $TbRecords,0,1,0,2) FileWriteLine($file3, $TbRecords [$b][1] & "," & $TbRecords [$b][2] & "," & $TbRecords [$b][3] & "," & $TbRecords [$b][4] & "," & $TbRecords [$b][5]) Nextthe file open and every thing is ok... there are 5 dimensions to the splitbut i get this errori cant find where the error is8)the first thing i'd suggest is to reformat your loop to a while instead of a For loop, because you're limiting the number of lines. I know that isn't what you were asking for, but just a tip. could you include some sample data that is being brought in? also is this error happening as soon as the script is run, or after some iterations? it's possible you have a blank line in the file, or a header line etc that isn't formatted the same, so you wouldnt' get the same number of elements from that line. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now