[SOLVED] How to speed up code to copy inserted row and clear contents?

Issue Sub CopyInsertRow() ActiveCell.Offset(1, 0).EntireRow.Insert ActiveCell.EntireRow.Copy ActiveCell.Offset(1, 0).EntireRow ActiveCell.Offset(1, 0).EntireRow.Font.Bold = False Cells(ActiveCell.Offset(1, 0).Row, 6).ClearContents Cells(ActiveCell.Offset(1, 0).Row, 4).ClearContents Cells(ActiveCell.Offset(1, 0).Row, 2).ClearContents Cells(ActiveCell.Offset(1, 0).Row, 3).HorizontalAlignment = xlRight End Sub This macro is to insert a new row, and then copy down

Continue reading

[SOLVED] Optimization of numpy array iteration

Issue I’m trying to optimize the performance of my python program and I think I have identified this piece of code as bottleneck: for i in range(len(green_list)): rgb_list = [] for j in range(len(green_list[i])): rgb_list.append(‘%02x%02x%02x’ % (red_list[i][j], green_list[i][j], blue_list[i][j])) write_file(str(i),

Continue reading