Macro Help

polo0320

New Member
Joined
May 10, 2011
Messages
1
Hi all.

-- removed inline image ---

Ok here is my problem, I have 2 types of lines, the yellow ones are my "BOL" lines and the greenish line is "CARRIER" line. What I want to do is insert with a macro button (NEW BOL) a new truck for the day. Since I don't plan on being the one inserting the data, I need to make the macro reference lines 5 and 6 (hidden) so that each BOL line looks like row 5 and the carrier line looks like row 6. Any ideas.

my current macro looks like this:

Sub InsertRow()
Dim Rng
Rng = InputBox("Enter number of BOL'S for new trailer.")
Range(ActiveCell.Offset(0, 0), ActiveCell.Offset(Rng - 1, 0)).Select
Selection.EntireRow.Insert
Range("A5:M5").Copy Destination:=ActiveCell
Selection.Insert Shift:=xlDown
Application.CutCopyMode = False
Range("A6:M6").Copy Destination:=ActiveCell
End Sub

All it will do is put the Carrier line at the top. I'm hoping there is a simple fix for this, but I doubt it. Thanks
 

Excel Facts

Easy bullets in Excel
If you have a numeric keypad, press Alt+7 on numeric keypad to type a bullet in Excel.

Forum statistics

Threads
1,224,585
Messages
6,179,703
Members
452,938
Latest member
babeneker

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