VBA Button to delete a row partially

4 Barrel Harold

New Member
Joined
Jun 15, 2018
Messages
21
Hey Guys and Gals, 4BBL Harold here with a problem that Ineed help with.<o:p></o:p>
On my sheet that I’m working on, I have a delete buttonsetup, here is brief description of the sheet<o:p></o:p>
I have two columns of information, 1ST columnsrange is E:M and 2ND Column O:W<o:p></o:p>
The rows start at row 12 and end at row 54<o:p></o:p>
Now here is what I’m trying to accomplish, if I select “H34”at random and press my VBA delete button, I need it to delete E:M on row 34without effecting O:W on same row and if I were to select another random cellon another row like R50 and press the same button it would delete O:W on row 50 and move lowerrows up O:W without deleting anything in E:M same row<o:p></o:p>
<o:p> </o:p>
<o:p> </o:p>
Application.ScreenUpdating = False<o:p></o:p>
ActiveSheet.Unprotect<o:p></o:p>
Dim ldel As Long<o:p></o:p>
ldel = MsgBox("Are You Sure You Want To DELETE SELECTEDITEM?", vbQuestion + vbYesNo)<o:p></o:p>
If ldel <> vbYes Then Exit Sub<o:p></o:p>
ActiveCell.EntireRow.Delete Shift:=xlShiftDown ßThis is the row I need Help on<o:p></o:p>
ActiveSheet.Protect<o:p></o:p>
Application.ScreenUpdating = True<o:p></o:p>
 

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.

Forum statistics

Threads
1,214,932
Messages
6,122,331
Members
449,077
Latest member
jmsotelo

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