I am using the script and have run into an issue. When the value for "n" exceeds 50, then it just opens one file and renames the colums, no matter the number of files selected. The error I recieve in the log is: Subscript Range in access or evaluation of 'y[n]' , y[/*###*/n].
Here is my current script.
Names Default To Here( 1 );
Files = Pick File(
"Select File(s)",
"C:\Users\dkraeuter\Desktop\Temp\Azure",
{"All Files|*"},
1,
0,
"",
"multiple"
);
y = {"Blank", "Feed Step 2", "Cycle Stopped", "Spindle Speed 1", "Spindle Speed 2", "Number of Stones",
"Percent of Surface Interuptions", "Honing Time ", "Tool Type", "Fault Code", "Serial Number", "Feed Force 1",
"Feed Force 2", "Bore Compensation", "Feed Position at Bore", "Feed Position at End", "Feed Position at Target",
"Wedge Angle", "Part Count", "Setup Name", "Part Material", "Part Hardness", "Stone Type", "Stone Length",
"Stone Width", "Coolant Type", "Cycle Run Status", "Cycle Stone Condition", "Cycle Incoming Condition",
"Machine Model", "Stroke Speed 1", "Stroke Speed 2", "Feed Rate 1", "Feed Rate 2", "Stroke Length", "Bore Length",
"VSRR Calc", "Average Torq Spindle", "Average Torq Stroker", "Average Torque Feed", "Average Feed Force",
"Average Part Torque", "Target Final Diameter", "Surface Finish Ra", "Surface Finish Rz", "Surface Finish Rt",
"1", "2", "3"};
For( i = 1, i <= N Items( Files ), i++,
Try( dt = Open( Files[i], "text" ) );
Wait( 0 );
For( n = 1, n < 56, n++,
Column( dt, n ) << Set Name( y[n] )
);
);