Can I automatically remove/prevent blank rows when saving as CSV from protected sheet with formulas?

kdorian

New Member
Joined
Aug 6, 2010
Messages
12
Is it possible to remove or prevent or blank rows at the end when saving an excel file as a CSV, if they are created by cells with formulas in a worksheet that is protected (rows cannot be deleted)? The formulas are basically =IF(Data!B2="","",Data!B2) links to either bring data from another sheet or another cell in the same worksheet, with a few IF statements thrown in.

The entire point of the protection is to prevent rows from being deleted, so I stop having to go in and fix a workbook that is "broken" because the user deleted rows containing formulas linked to another worksheet (again). This means that deleting blank rows at the end before saving isn't possible. Barring macros, am I stuck with the blank rows at the end?

(Yes, copying the data to a new sheet and saving it from there would fix it, but is not going to happen. Please keep in mind we are talking about an end user who keeps deleting rows after being told it will break the sheet, and whose response to any problem in a workbook that has had a macro run in it is "the macro broke it". Yes, I might be a little salty.)
 

Excel Facts

Back into an answer in Excel
Use Data, What-If Analysis, Goal Seek to find the correct input cell value to reach a desired result

Forum statistics

Threads
1,215,069
Messages
6,122,958
Members
449,096
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