Great that worked for me. Thank you. I had to get rid of my original loop because it would loop through then loop through again.
One more thing on this. After I put this in and got rid of my other loop it seems to go through each cell with data then an additional one because it returns an error that I put into the sheet that if recordset = 0. I verified that all the data was returned for what was listed in that column and it was.
Also tried to update a pivot table for this like....
VBA Code:
With Worksheets("Data_Col").PivotTables("PivotTable3").PivotFields("PROCESS_BATCH") .PivotItems(" " & nxtval & " ").Visible = True End With
Gives error Unable to get the PivotItems property of the PivotField class. It does however under debug display the correct batch number.