Inserting rows when value's are input into cells

cdude911

New Member
Joined
Jul 20, 2022
Messages
17
Office Version
  1. 2016
Platform
  1. Windows
So I have a worksheet that has entry's for data for every day of the month. The layout repeats every 6 rows for the entire month. My goal is that when a value is entered into the last formatted cell in column E for a day then a row would be inserted below it copying the formatting of the row that just had data entered and adding the value "N" to column b of the new row and a formula adding column h and j to column k.

So for example if i entered a value in cell E5 then a row would be inserted below it copying the formatting of row 5 and including the value and formula I specified in columns b and k. Then if a value was added to E6 it would do the same thing and so on and do this for every day.

I have attempted using ChatGPT to help me as I have very limited VBA knowledge and have not been getting anything to work. After allowing it to try multiple things I tried steering it in the direction of creating an inital list of cell references that starts at cell e5 and contains the reference for every 6 rows on until row 1000. Then if a value was input into column e anywhere it would check if that cell reference matched anything on the list and then would insert the row and then add 1 to the row value of the matched reference and every value that followed it on the list. I am unsure if this is the optimal way to go about solving this but any help at all would be greatly appreciated. I'll gladly answer any questions to clear up my objective or anything else you need.
 

Attachments

  • flight log screenshot.PNG
    flight log screenshot.PNG
    103.8 KB · Views: 12

Excel Facts

Save Often
If you start asking yourself if now is a good time to save your Excel workbook, the answer is Yes

Forum statistics

Threads
1,215,072
Messages
6,122,966
Members
449,094
Latest member
Anshu121

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