browncountry
New Member
- Joined
- Feb 2, 2019
- Messages
- 13
[TABLE="class: grid, width: 500, align: center"]
<tbody>[TR]
[TD][/TD]
[TD]A[/TD]
[TD]B[/TD]
[TD]C[/TD]
[TD]D[/TD]
[TD]E[/TD]
[/TR]
[TR]
[TD]1[/TD]
[TD]Work Center[/TD]
[TD]Part Number[/TD]
[TD]Description[/TD]
[TD]Qty Good[/TD]
[TD]Qty Scrap[/TD]
[/TR]
[TR]
[TD]2[/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD]3[/TD]
[TD]1234[/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD]4[/TD]
[TD][/TD]
[TD]Part A[/TD]
[TD]DescriptA[/TD]
[TD]20[/TD]
[TD]2[/TD]
[/TR]
[TR]
[TD]5[/TD]
[TD][/TD]
[TD]Part B[/TD]
[TD]DescriptB[/TD]
[TD]5[/TD]
[TD]1[/TD]
[/TR]
[TR]
[TD]6[/TD]
[TD]5678[/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD]7[/TD]
[TD][/TD]
[TD]Part C[/TD]
[TD]DescriptC[/TD]
[TD]56[/TD]
[TD]4[/TD]
[/TR]
[TR]
[TD]8[/TD]
[TD][/TD]
[TD]Part D[/TD]
[TD]DescriptD[/TD]
[TD]45[/TD]
[TD]2[/TD]
[/TR]
[TR]
[TD]9[/TD]
[TD][/TD]
[TD]Part E[/TD]
[TD]DescriptE[/TD]
[TD]90[/TD]
[TD]0[/TD]
[/TR]
[TR]
[TD]10[/TD]
[TD]9012[/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD]11[/TD]
[TD][/TD]
[TD]Part F[/TD]
[TD]DescriptF[/TD]
[TD]12[/TD]
[TD]2[/TD]
[/TR]
</tbody>[/TABLE]
If anyone has time, I would like help with VBA to search for Work Centers in Column A and then merge that cell across to Column E.
The end result in my example is for my work centers to be headers of each group and centered across all columns. Work Center 1234 is merged from A3:E3; Work Center 5678 is merged from A6:E6; Work Center 9012 is merged from A10:E10.
I would also like to shade those merged cells to a light gray if possible. Thanks if you're able to help.
<tbody>[TR]
[TD][/TD]
[TD]A[/TD]
[TD]B[/TD]
[TD]C[/TD]
[TD]D[/TD]
[TD]E[/TD]
[/TR]
[TR]
[TD]1[/TD]
[TD]Work Center[/TD]
[TD]Part Number[/TD]
[TD]Description[/TD]
[TD]Qty Good[/TD]
[TD]Qty Scrap[/TD]
[/TR]
[TR]
[TD]2[/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD]3[/TD]
[TD]1234[/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD]4[/TD]
[TD][/TD]
[TD]Part A[/TD]
[TD]DescriptA[/TD]
[TD]20[/TD]
[TD]2[/TD]
[/TR]
[TR]
[TD]5[/TD]
[TD][/TD]
[TD]Part B[/TD]
[TD]DescriptB[/TD]
[TD]5[/TD]
[TD]1[/TD]
[/TR]
[TR]
[TD]6[/TD]
[TD]5678[/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD]7[/TD]
[TD][/TD]
[TD]Part C[/TD]
[TD]DescriptC[/TD]
[TD]56[/TD]
[TD]4[/TD]
[/TR]
[TR]
[TD]8[/TD]
[TD][/TD]
[TD]Part D[/TD]
[TD]DescriptD[/TD]
[TD]45[/TD]
[TD]2[/TD]
[/TR]
[TR]
[TD]9[/TD]
[TD][/TD]
[TD]Part E[/TD]
[TD]DescriptE[/TD]
[TD]90[/TD]
[TD]0[/TD]
[/TR]
[TR]
[TD]10[/TD]
[TD]9012[/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD]11[/TD]
[TD][/TD]
[TD]Part F[/TD]
[TD]DescriptF[/TD]
[TD]12[/TD]
[TD]2[/TD]
[/TR]
</tbody>[/TABLE]
If anyone has time, I would like help with VBA to search for Work Centers in Column A and then merge that cell across to Column E.
The end result in my example is for my work centers to be headers of each group and centered across all columns. Work Center 1234 is merged from A3:E3; Work Center 5678 is merged from A6:E6; Work Center 9012 is merged from A10:E10.
I would also like to shade those merged cells to a light gray if possible. Thanks if you're able to help.