Need to add rows based on previous column values

csimpson24

New Member
Joined
Feb 22, 2018
Messages
22
Hello all,

Ripping my hair out over this one and cannot find an answer anywhere. Here is an example of my data. I want to automatically add a new row after the last job entry. So in the example below, I would add a new row for job 106144 with Opr 60, a new row for job 108422 with Opr 30, a new row for Job 108466 with Opr 20, and so on. Any help would be GREATLY appreciated. It's been years since I've written in VBA by the way.

[TABLE="width: 527"]
<tbody>[TR]
[TD][TABLE="width: 527"]
<tbody>[TR]
[TD]JobNum[/TD]
[TD]Company[/TD]
[TD]Plant[/TD]
[TD]Asm[/TD]
[TD]Opr[/TD]
[TD]Operation[/TD]
[/TR]
</tbody>[/TABLE]
[TABLE="width: 527"]
<colgroup><col><col span="2"><col span="2"><col></colgroup><tbody>[TR]
[TD]106144[/TD]
[TD]GCB[/TD]
[TD]GCB[/TD]
[TD]0[/TD]
[TD]10[/TD]
[TD]MECHENG[/TD]
[/TR]
[TR]
[TD]106144[/TD]
[TD]GCB[/TD]
[TD]GCB[/TD]
[TD]0[/TD]
[TD]20[/TD]
[TD]MACH[/TD]
[/TR]
[TR]
[TD]106144[/TD]
[TD]GCB[/TD]
[TD]GCB[/TD]
[TD]0[/TD]
[TD]30[/TD]
[TD]FAB[/TD]
[/TR]
[TR]
[TD]106144[/TD]
[TD]GCB[/TD]
[TD]GCB[/TD]
[TD]0[/TD]
[TD]40[/TD]
[TD]ASSEM[/TD]
[/TR]
[TR]
[TD]106144[/TD]
[TD]GCB[/TD]
[TD]GCB[/TD]
[TD]0[/TD]
[TD]50[/TD]
[TD]TEST[/TD]
[/TR]
</tbody>[/TABLE]
[/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
</tbody>[/TABLE]

[TABLE="width: 527"]
<colgroup><col><col span="2"><col span="2"><col></colgroup><tbody>[TR]
[TD]108422[/TD]
[TD]GCB[/TD]
[TD]GCB[/TD]
[TD]0[/TD]
[TD]10[/TD]
[TD]FAB[/TD]
[/TR]
[TR]
[TD]108422[/TD]
[TD]GCB[/TD]
[TD]GCB[/TD]
[TD]0[/TD]
[TD]20[/TD]
[TD]MACH[/TD]
[/TR]
</tbody>[/TABLE]
[TABLE="width: 527"]
<colgroup><col><col span="2"><col span="2"><col></colgroup><tbody>[TR]
[TD]108446[/TD]
[TD]GCB[/TD]
[TD]GCB[/TD]
[TD]0[/TD]
[TD]10[/TD]
[TD]MACH[/TD]
[/TR]
[TR]
[TD]108449[/TD]
[TD]GCB[/TD]
[TD]GCB[/TD]
[TD]0[/TD]
[TD]10[/TD]
[TD]FAB[/TD]
[/TR]
[TR]
[TD]108449[/TD]
[TD]GCB[/TD]
[TD]GCB[/TD]
[TD]0[/TD]
[TD]20[/TD]
[TD]MACH[/TD]
[/TR]
</tbody>[/TABLE]
 
Glad to help & thanks for the feedback
 
Upvote 0

Excel Facts

What did Pito Salas invent?
Pito Salas, working for Lotus, popularized what would become to be pivot tables. It was released as Lotus Improv in 1989.

Forum statistics

Threads
1,226,730
Messages
6,192,702
Members
453,748
Latest member
akhtarf3

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top