VBA Find Last Row and Insert Empty Row Below but Keep Drop-Downs

dd04518

New Member
Joined
Sep 5, 2020
Messages
8
Office Version
  1. 365
Platform
  1. Windows
I have a spreadsheet that has multiple columns with drop-downs as well as data formatting for numbers. I need to have a macro that I can assign a button to that will find the last row with data and then insert an empty row beneath it but keep the drop-downs for the columns and the formatting of the data types in the cells. The sheet has 19 columns. I'm very new to VBA coding. I searched the forum for a thread but didn't find what I needed. Thank you.
 
any time you are inserting or deleting rows on a sheet with formulas there is a good chance that the the formulas will lose their original precedent or dependent cells and become invalid. Trying to write code without having the worksheet to see where formulas reside and what rows and columns are affected by the formulas is a risky venture. Some cells with formulas can be shifted with no change in how the formula performs. Shifting other cells with formulas can have disastrous effect on the formulas. The user has to evaluate those probabilities in deciding to use macro procedures or not to insert or delete rows.
 
Upvote 0

Excel Facts

Links? Where??
If Excel says you have links but you can't find them, go to Formulas, Name Manager. Look for old links to dead workbooks & delete.
Ahhh, ok. That makes sense. I appreciate the explanation.

Any suggestions on how to work this out? Did I build the sheet wrong in the 1st place (prior to the vba code)? Is this a question I should start a new thread on?
 
Upvote 0
I cannot evaluate whether your sheet is built correctly or not because I have no idea what data you are working with nor the purpose of any any of it. But there are rules that apply to using formulas in Excel which determine when , where and how a formula can be applied, relocated, etc. It takes entire books to explain the ins and outs of Excel so I will not attempt to explain it here other than to say it is all based on logical process.
 
Upvote 0

Forum statistics

Threads
1,214,591
Messages
6,120,427
Members
448,961
Latest member
nzskater

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